create new tag
, view all tags
"LISP: The Language of Artificial Intelligence", by A. A. Berk, seems to be just the book I need to learn LISP.



The Book

"LISP: The Language of Artificial Intelligence", A. A. Berk, Van Nostrand Reinhold, © 1985, ISBN: 0-442-20974-6 — I found it at the NCACC library.


I almost don't want to make any, but just make notes based on what I've learned / am learning from the book. I think it is an excellent book, just what I needed to learn LISP. I could tell the story of my past experience with LISP — for now, suffice it to say that I left my only LISP class (which I did pass), with the firm conviction that LISP was worthless. Then I learned that the scripting language for AutoCad was LISP, and people did manage to write scripts in it. I was amazed, but didn't dig deep enough to learn how they actually did it. Somehow my impression of LISP from the first class was that all it did was use CAR and CDR to fool around with lists (even though I'm sure we did encounter math functions and so forth). Anyway ...

BTW, since I'm starting to understand LISP better, it doesn't look as worthless as it once did. It seems that processing lists can be very useful. It appears to me though, that a LISP interpreter has to be on the order of an order of magnitude slower than say, a C program just because its primitives (like CAR and CDR) are not (IIUC) machine / assembly language primitives. (Was there once a LISP machine? IIRC, the Burroughs 5500 (??) was a stack machine, I have this faint recollection that there was also a LISP machine built (or at least proposed).)

I also toyed with the idea that someone might learn LISP quicker if books started with more normal computer functions (math, whatever) and got to the list processing CAR and CDR stuff later. I had the impression for awhile that learning the CAR and CDR stuff was like dues (or penance) — the LISP gurus would not let you have the secrets of LISP until you suffered through the same things they did, even though that information was (IMO at the time) totally unused once you got past it into the "real meat" of LISP (math functions and so forth). I think I'm dropping that mindset, but it still lurks.

LISP Concepts and Functions

There are some subtleties that the book points out that I haven't necessarily recorded here. One is the difference between EQ and EQUAL, i.e., the difference between two lists being equal because they contain the same atoms (EQUAL) vs. the lists being identical because their labels (names, whatever) point to the same "location" in memory (EQ).

Words or numbers, any item which is not a list. "A single string of any type of character, with no spaces included. For example:

     -17     Fred2-Smith     one2three     1256"

"a set of any number of atoms and/or lists separated by spaces and contained within round brackets. For example:

     (12 3 7)     (A B (C D (E) F G))"

Atoms which are not pure numbers, atoms that form a valid "name". (In most LISPs, an identifier must start with a letter.) "an atom which is not a pure number, and may be thus used as a variable or function name. For example:

     Odd-number     X24     multiply-by-2"

Reminders (to me, at least):

  • remember that an identifier is an atom (that is not a pure number)
  • "round brackets" are what I would call "parentheses" (don't know if the round brackets is a "Canadianism" or a "Lispism" wink )

Concepts and Terminology

Tail Recursion

IIUC, the concept of a compiler recognizing that a recursive function can be converted to a loop and doing so. (Maybe that's tail recursion optimization or some such.)


  • () RandyKramer - 06 May 2003
  • If you edit this page: add your name here; move this to the next line; and if you've used a comment marker (your initials in parenthesis), include it before your WikiName.

Page Ratings

Edit | Attach | Watch | Print version | History: r2 < r1 | Backlinks | Raw View | Raw edit | More topic actions
Topic revision: r2 - 2003-05-06 - RandyKramer
  • Learn about TWiki  
  • Download TWiki
This site is powered by the TWiki collaboration platform Powered by PerlCopyright 1999-2017 by the contributing authors. All material on this collaboration platform is the property of the contributing authors.
Ideas, requests, problems regarding WikiLearn? WebBottomBar">Send feedback
See TWiki's New Look