Rigidly defined areas of doubt and uncertainty.

Sunday, May 22, 2005

What a program is

"Programs must be written for people to read, and only incidentally for machines to execute."

- Abelson & Sussman, SICP, preface to the first edition

These words ring very true to me right now, as I read through reams of open source code composed of deeply nested six page long if statements, sparse one-line comments and a smattering of global variables for extra flavour.

My own formulation of the same sentiment might be "Programs are documents used by programmers to communicate their ideas to each other, which also happen to be readable by computers." Or more briefly "Code is documentation".

Now any book that starts with a statement like that must be worth reading. It's been on my to-read list for a long time, but never really seemed essential. Now I think it is. The systems I work with are getting bigger and more complex, so I need more guidance on how to deal with that.

No comments: