The roots of Lisp by Paul Graham
In this
article, the author Paul Graham tells the history (“the roots”) of the programming language Lisp. John McCarthy has
built Lisp in 1958 with only few simple operators and a notation for functions.
The name Lisp is a mix of the words “List” and “Processing”. Full of mockery
was made because of the use of many parentheses in the Lisp syntax, giving a
funny acronym for LISP: "Lots of Irritating and Silly Parentheses". Because
of its expressiveness and flexibility, Lisp had a lot of success in the
artificial intelligence community.
For the
author, there are 2 unavoidable models nowadays: The C and Lisp programming
languages, which influence the most recent languages (Most of the time, they
are composed of a C base with adding Lisps parts, like runtime typing and
garbage collection).
Paul Graham
also explains how John McCarthy obtained his new model of computation by
creating functions (eval). Lisp is a
language that does not distinguish between "expressions" and
"instructions" as many programming languages do. Clojure programs are
composed of expressions. First of all, an expression is a sequence of letters
or a list separated by whitespace and enclosed by parentheses. (foo bar) is an example of an expression
(which is a list of 2 elements). The first element of a list is called an
operator (examples: quote, atom, eq, car,
cdr, cons, cond); the others are called the arguments. There are 3 main
characteristics in the Lisp syntax: a Lisp program is a list of expressions, an
expression can be an atom or a list (recursion), and an atom is either a
number, a name, a string of characters, an operator.
The
question that we can ask to ourselves is “why McCarthy didn’t use an already
known model of computation such as the Turing machine?” These programs were just
not enough interesting for the Lisp creator, not very edifying for him to read.
Commentaires
Enregistrer un commentaire