10th rule of programming

Philip Greenspun's Homepage : Philip Greenspun's Homepage Discussion Forums : Ask Philip : One Thread
Notify me of new responses
Your 10th law on programming (every complicated C or Fortran program
duplicates LISP, badly), has become rather famous. However, I searched
in vain for the origin of this law. What are the other 9 laws, and how
did you come to formulate them?

-- Han-Wen Nienhuys, September 27, 2003


Sorry, Han-Wen, but there aren't 9 preceding laws. I was just trying to give the rule a memorable name. (A Google search brought up the original phrase as "Any sufficiently complicated C or Fortran program contains an ad-hoc, informally-specified bug-ridden slow implementation of half of Common Lisp.") I have only a dim recollection of writing this originally. It might have been in 1993 for an MIT AI Lab Technical Report describing software for automating earthworks design and construction (most of which I actually built in the late 1980s). There was a short section on why Common Lisp and the old Symbolics Lisp Machine made it possible for one programmer to get so much done (graphics library, user interface, 3D surface models, computational geometry algorithms, interface to actual equipment, etc.).

It is ironic that this will, after my death, probably be the one thing that anyone remembers from my writing. I was just a punk when Common Lisp was standardized by a bunch of guys who'd been writing Lisp code for 10 years or more. Although I contributed a few fixes and minor improvements to the Lisp Machine operating system, I was always more interested in application programs and put 99 percent of my effort into building some big computer-aided engineering systems. So I definitely don't belong in the pantheon of Lisp Gods. I'm an impatient pragmatist and hate to spend time working on tools. When I start a project, I survey my friends who are experts to find out what the best tools are, and then run with it. So when I was a nerdlet at MIT it was the MIT Lisp Machine. When I was building my first large-scale multi-user Internet applications, it was Oracle.

-- Philip Greenspun, September 27, 2003