Still throws me that “order” here means something like “instruction” as in “that’s an order, lieutenant!” and “code” means something like “set,” as in “legal code” or “code of conduct.”

“Program” however is already used here by Knuth in more of the contemporary sense, though I gather in the time of ENIAC and EDVAC, a “program” was more narrowly the sequence of operations that implemented an order/instruction.

What I love most about all this, though, is how much of the machine you can see in the algorithm and the programming. You can almost visualize the vacuum tubes turning on and off in response to these instructions, which themselves would have been electrical pulses arranged into patterns according to the positions of a bunch of Bakelite switches. Just amazing.

The title states that this is von Neumann’s “first computer program,” but the writing includes plenty of indicators to the contrary and introduces the qualifiers “stored” and “extant.”

Maybe Knuth will issue a reward check to someone who emails him to fix the title?

Extremely surprising reading about his mental arithmetic errors (!) and misunderstandings, forgetting about variables, etc.
Sorting has always been a bellwether for computing systems. Interestingly, Jim Gray recognized that 45 years later. He therefore initiated and evangelized the out of core Sort Benchmarks (
I believe some researchers have come to the conclusion that "the earliest extant program for a stored program digital computer" was not written by John von Neumann, but by his wife: Klára Dán von Neumann.

Knuth references a letter "in the possession of Dr. Herman H. Goldstein," but scholars making the case for Klara are usually referencing the archival materials at the LoC:

I'm doing some research that involves this issue, and I'd be grateful to anyone who has any insight on this. There's a book called Klara and the Bomb, which is quite fascinating (and makes the claim for Klara), but that book leans more toward art than research scholarship.

I am aware that "firsts" are often hard to identify when it comes to the history of science and technology; I'm personally more interested in what these very early programs were being used for than who wrote them, per se. But I'd still like to know if Knuth is actually correct in his assumption.


Von Neumann's First Computer Program (1970) - - Jan 2023 (9 comments)

Von Neumann’s First Computer Program (1970) - - May 2018 (18 comments)

“[John von Neumann] probably never intended to have this program published and subjected to such scrutiny; although his manuscript is carefully documented, he probably wanted only to circulate it among a few interested colleagues. So when we find a few errors and a few instances of clumsy coding, we should realize that it was an early effort that was not supposed to represent a polished product.”
tl;dr a variation of merge sort. Which is still one of the best sorting algorithms ever devised.

Pretty impressive for the first stored computer program ever.