01Overview
In 1958 McCarthy designed LISP at MIT, initially for symbolic differentiation and AI research. S-expressions represent both code and data, and eval lets a program build and run programs. That homoiconicity is what makes macros possible.
LISP also gave us much of today’s infrastructure: McCarthy proposed garbage collection in 1960, the REPL made interactive development a habit, and Scheme brought tail calls and lexical scope into teaching. Clojure and Racket continue the line, and many of JavaScript’s design choices trace back to it.
02History
- 1958
LISP appears
McCarthy designs it at MIT, bringing the lambda calculus into programming languages.
- 1960
Garbage collection
The beginning of automatic memory management.
- 1975
Scheme
A minimalist Lisp dialect.
- 1984
Common Lisp
A large, standardised Lisp.
- 2007
Clojure
A modern Lisp on the JVM.
03Core concepts
S-expressions
Code and data in one uniform notation of parentheses and prefixes.
Homoiconicity
A program can be read, modified and generated like data.
Macros
Transform code at compile time and extend the syntax of the language.
04Hands-on
Do it once — it beats reading it ten times
Implement a 40-line Lisp interpreter that supports define, lambda, if and arithmetic
05Self-check
Say it in your own words first, then open the answer. Whatever you cannot explain is what to review next.
Can you explain "S-expressions"?
Code and data in one uniform notation of parentheses and prefixes.
Can you explain "Homoiconicity"?
A program can be read, modified and generated like data.
Can you explain "Macros"?
Transform code at compile time and extend the syntax of the language.
What problem did it solve, and why was there nothing better at the time?
Go back to the history section: how was this done before, and what did it cost?
If you had to build it today, how would you break it down?
Use the hands-on task above: write a plan of at most three steps before you start.
06Key people
John McCarthy
1927 – 2011
Inventor of LISP; a pioneer of AI.
Guy Steele
1954 –
Co-designer of Scheme; parallelism and language design.
07Further reading
- Structure and Interpretation of Computer Programs
- LISP 1.5 Programmer’s Manual