Stefan Tilkov's Random Stuff

Code Reads #4: Dijkstra's 'Notes on Structured Programming'

Scott Rosenberg publishes a series of essays about influential computer science papers; all of them are very much worth reading. This time, he takes a look at Dijkstra’s paper from 1970:

At the heart of “Notes on Structured Programming” lies Dijkstra’s advocacy of a particular approach to a program’s layered structure: “Each program layer is to be understood all by itself, under the assumption of a suitable machine to execute it, while the function of each layer is to simulate the machine that is assumed to be available on the level immediately above it.” This “imaginary hardware” vision of abstraction may be foreign to the contemporary programming mindset; Dijkstra explains (in “What Led to ‘Notes…’”) that he’d come to this way of thinking from his experiences early in his career of writing software for hardware that was still being built and couldn’t yet run the programs. He worked that way so the code would be ready in time to ship with the new machines.

This reminds me of a Paul Graham essay — Dijkstra’s machine was hardware, Graham’s is software (and grows to meet the program’s needs).

Comments