An important feature of Lisp for AI applications is the ability to construct new symbolic structures of arbitrary size and complexity at runtime.
A new list structure with a fixed number of elements can be made using the function LIST. To make a list of items x1 ... xn, use the form:
(LIST x1 ... xn)
Each argument of LIST is evaluated unless it is quoted.
(LIST 'X 'Y 'Z) = (X Y Z) (LIST (+ 2 3) (* 2 3)) = (5 6) (SETQ MAN 'ADAM) (SETQ WOMAN 'EVE) (LIST MAN 'LOVES WOMAN) = (ADAM LOVES EVE) (LIST (LIST 'A 'B) (LIST 'C 'D)) = ((A B) (C D))
Contents    Page-10    Prev    Next    Page+10    Index