This webpage is a collection of LISP resources that will be helpful to
the class members of CSC 244/444. I will update here very often at the
beginning of the sememster. Suggestions are always welcome.
Tutorial:
At 6:15pm on Sept 7, there was a hour-long tutorial on the basics
of LISP. In the tutorial, I went through the elements of LISP
and a
few miniature programs that demonstrate the basic constructs and show
the programming style of LISP. The materials are:
Lisp Primer
- a one day tutorial, recommended for self learning.
References:
Common
Lisp the Language, 2nd Edition - this is one of the most
comprehensive references if you need to look up the available functions
or parameters. Probably you want to bookmark the index page for easy
reference
while programming. For those on the graduate cs network, there is a
local copy at /p/lisp/cltl/cltl2.html . A print copy
is also available in the graduate
lab.
ANSI
Common Lisp - the other comprehensive and authoritive reference.
It's organized into chapters of topics. Any given chapter might contain
conceptual material, dictionary entries, or both.
An
Introduction and Tutorial for Common Lisp - an excellent collection
of handouts and links both for beginners and advanced LISP users.
However, this webpage has not been updated for quite a while and some
links are broken as well. I felt these pointers recommendable:
The Dynamic
Learning Center - a center of lisp resources for both students and
teachers. Also included are links to resourceful lisp websites,
free-to-download LISP books.
Development environments:
Emacs is the recommended editor for lisp programming. And it's
more than an editor. Here, I describe how to run Allegro Common Lisp
(an implementation of CL) within emacs.
First of all, you need to load the initialization code for the FI
(Franz Inc.) emacs-lisp interface into emacs. You can either run emacs
using the command line:
emacs -l
/p/lisp/acl/linux/urcs/fi-init.el - for
grads emacs -l
/usr/staff/acl/latest/eli/fi-site-init.el - for undergrads
Or add the following line (load
"/p/lisp/acl/linux/urcs/fi-init.el") - for grads (load
"/usr/staff/acl/latest/eli/fi-site-init.el") - for undergrads
to the .emacs file in your
home directory so as to make emacs load the FI every time it is started.
Once emacs is loaded with the FI interface, you can invoke alisp via a
simple meta-key command:
Meta-x lisp or Meta-x allegro - for grads Meta-x fi:common-lisp -
for undergrads
Then, you will be asked a few questions such as which directory to work
in, which host to run on, etc. In normal cases, you can press "Enter"
key all the way until a lisp buffer is displayed.
We have a good tutorial on running
and debugging in Allegro Lisp, written by a former TA. .clinit.cl
- is the init file needed for debugging mentioned in the tutorial.
If you prefer doing editing and running/debugging in separate
programs, you can invoke a lisp interpreter from within a shell.
Currently, there are two dialects of Common Lisp installed in the grad
network.
lisp now stands for cmucl, the CMU Common Lisp acl is linked to alisp, the Allegro Common
Lisp
In the csug network, there is only the latest version of Allegro Lisp
installed. lisp, alisp, cl, cll, clll all
point to the same interpreter.
You probably will wish to have the convenience of command line editing
and command history looking-up for the interpreters. A good stuff to
try out is: rlwrap, which will upgrade your
interpreter with the line editting functionalities of modern shells.
Many Thanks to Phil Michalak, Myrosia
Dzikovska, and Fabrizio Morbini