The Thinking Machine Chronicles #0013: The Baby That Changed Everything: The First Stored-Program Computer Runs

Piet Mondrian, Broadway Boogie Woogie, 1942–43. Oil on canvas. Museum of Modern Art, New York. Public domain (artist died 1944). Painted in the same years that Williams and Kilburn were designing the CRT memory that would store the world's first program, each yellow block a bit, each grid line an address.
Era 1 · The Foundations (1936–1955) A 32-word machine in a Manchester stable takes 52 minutes to find the highest factor of 262,144. The calculation is trivial. The fact that the program lived inside the machine's own memory, and could be changed without rewiring,is the most consequential engineering decision of the twentieth century.
The World in 1948
The world in June 1948 was balanced between relief that the war was three years past and dread that a new one was forming. In January, Mahatma Gandhi had been assassinated in New Delhi's Birla House, four months after the partition of British India into two nations at a cost of perhaps two million lives. In May, the British Mandate in Palestine ended and the State of Israel was proclaimed, followed within hours by the invasion of five Arab armies. On 24 June 1948,three days after the Manchester Baby ran its first program, Soviet forces completed the encirclement of West Berlin, closing every road and rail line from the West in the opening move of the Berlin Blockade; the Allied airlift would run for eleven months and 200,000 flights. In Washington, the Marshall Plan had been signed into law in April, committing thirteen billion dollars to rebuild the shattered economies of Western Europe. Harry Truman would surprise every pollster in November. The Universal Declaration of Human Rights would be adopted in December.
At the University of Manchester, the intellectual atmosphere was shaped by two recent imports: Freddie Williams, a radar engineer who had joined from TRE Malvern, and Tom Kilburn, his research student and closest collaborator. Williams had spent the war perfecting cathode ray tube technology for radar displays; he arrived at Manchester in 1946 with an idea that the same CRT phosphor, which retained a faint afterglow when struck by an electron beam, could be used to store binary data. He and Kilburn had been developing what would be called the Williams tube, a memory device that could store and retrieve individual bits by reading and writing charge patterns on a standard television tube. By the spring of 1948 they had a working prototype and the skeleton of a machine to test it.
Williams, Kilburn, and the Machine in the Stable
The Small-Scale Experimental Machine (SSEM), known almost immediately as "the Baby," was not designed to be useful. It was designed to be a test bed for the Williams tube, proof that the storage technology worked, that it could hold a program and data reliably long enough to compute something. The machine occupied a 5.2 × 2.2 metre frame in the Computing Machine Laboratory, a converted stable in the grounds of the university. It had 32 words of 32-bit memory, a single accumulator, and a control unit built from surplus valve equipment and point-contact transistors. It had no input beyond switch settings, no output beyond the glow of the CRT.
Williams and Kilburn chose the simplest program they could think of that would stress-test the machine: find the highest factor of a given integer by trial division. They chose , a number with a known factorisation, large enough to require genuine computation. The program required 17 instructions. On 21 June 1948, at an unremarked moment in the afternoon, the Baby ran it. It took 52 minutes and 3.5 million operations. The answer,131,072, which is , was correct.
Nobody present described the occasion as historic. Williams later recalled that the result "came up on the display and we knew it was right." Kilburn did not make a note in his lab book. They ran a few more tests, went home, and came back the next morning to run more.
The Problem They Were Solving
Every computer before June 1948 was either fixed-function (built to do one thing) or programmed by rewiring, by physically reconnecting the hardware to change the sequence of operations. ENIAC, which we examined in TMC #0009, required operators to spend days resetting switches and plugboards to change programs. Zuse's Z3 read instructions from punched tape but could not store them internally or modify them during execution.
The stored-program concept, the idea that program instructions and data should live in the same addressable memory, be operated on by the same instruction fetch-decode-execute cycle, and be modifiable by the program itself,had been articulated by Von Neumann and the EDVAC team in 1945 (see TMC #0007). But articulation is not demonstration. The Baby was the first machine to actually do it.
The SSEM Instruction Set
The Baby had exactly seven distinct operations, encoded in three bits (bits 13–15 of each 32-bit word). Addresses were 5 bits (bits 0–4), pointing to one of the 32 memory locations. The instruction format:
| Bits 0–4 | Bits 5–12 | Bits 13–15 | Meaning |
|---|---|---|---|
| Address | (unused) | Opcode | Instruction |
The complete instruction set:
| Opcode (binary) | Mnemonic | Operation |
|---|---|---|
000 | JMP S | Jump: load line S into CI (current instruction counter) |
001 | JRP S | Relative jump: add content of line S to CI |
010 | LDN S | Load negative: accumulator ← −mem[S] |
011 | STO S | Store: mem[S] ← accumulator |
100 or 101 | SUB S | Subtract: accumulator ← accumulator − mem[S] |
110 | CMP | Skip next instruction if accumulator < 0 |
111 | STP | Stop |
There is no ADD instruction. Addition is performed by loading the negated operand (LDN) and subtracting its negation (SUB):
There is no unconditional branch to a fixed address, JMP S loads the contents of memory location S into the instruction counter, so to jump to address 7 you store the value 7 somewhere in memory and JMP to that storage location.
The First Program
The highest-factor program used the following algorithm: starting from and counting down to 1, test each candidate divisor : if , record as the current best and continue. The SSEM computed by successive subtraction. The 17-instruction program in SSEM assembly (using modern notation):
line instruction comment
0 JMP 0 ; halt — used as jump target
1 LDN 24 ; acc = -n (load negated trial divisor)
2 STO 26 ; store -d in line 26
3 LDN 26 ; acc = d
4 STO 27 ; store d in line 27
5 LDN 23 ; acc = -n (load negated dividend)
6 SUB 27 ; acc -= d (acc = -n - d)
...
The program's inner loop executed repeatedly until the accumulator went non-negative, at which point CMP caused a skip and the outer loop moved to the next candidate. The complete 17-line program is reproduced in full in the companion project.
The Baby's first run, 21 June 1948
Tom Kilburn's lab notebook records the date but not the time. The result, that the highest factor of is ,was correctly produced after 3.5 million operations and approximately 52 minutes of execution. A subsequent test on ran for nine hours. The SSEM was publicly announced in a letter to Nature by Williams, Kilburn, and Tootill on 12 October 1948.
Williams, F.C. & Kilburn, T. (1948). Electronic Digital Computers. Nature, 162(4117), 487. The original announcement, one column in length, describing the stored-program machine that changed computing.
The Code: SSEM Simulator
The companion project implements a complete SSEM simulator in pure Python, including all seven instructions, a 32-word memory, and the original highest-factor program. The memory is represented as a list of 32-bit integers with bit-reversal (the SSEM stored values with LSB at bit 0):
def execute(self) -> int:
"""Run until STP. Returns the number of instructions executed."""
count = 0
while True:
self.ci = (self.ci + 1) % 32 # fetch: increment CI
instr = self.memory[self.ci]
addr = instr & 0x1F # bits 0-4
op = (instr >> 13) & 0x7 # bits 13-15
count += 1
if op == 0b000: self.ci = self.memory[addr] # JMP
elif op == 0b001: self.ci = (self.ci + self.memory[addr]) & 0x1F # JRP
elif op == 0b010: self.acc = -self._signed(self.memory[addr]) # LDN
elif op == 0b011: self.memory[addr] = self.acc & 0xFFFFFFFF # STO
elif op in (0b100, 0b101):
self.acc -= self._signed(self.memory[addr]) # SUB
elif op == 0b110: # CMP
if self.acc < 0: self.ci = (self.ci + 1) % 32
elif op == 0b111: return count # STP
The full project loads and runs the original 1948 highest-factor program, prints the step-by-step register trace, and verifies the result against the known factorisation of .
Why It Mattered
The Baby mattered for one reason that has compounded for seventy-six years: the program was data.
When a program lives in the same memory as its data, it can be modified at runtime. Self-modifying code, loops that unroll themselves, operating systems that load other programs, none of these are possible on a hardwired machine. The stored-program architecture is what allows a general-purpose computer to be general-purpose: the same hardware runs a weather simulation in the morning, a database query in the afternoon, and a chess engine in the evening, because the program is not wired in but written.
The Baby also validated the Williams tube as a practical memory technology, which directly enabled the Manchester Mark 1 (operational in 1949) and the Ferranti Mark 1 (1951), the world's first commercially available computer. It demonstrated that the theoretical EDVAC architecture could be built with valves and phosphor, and encouraged Eckert and Mauchly in Philadelphia, Maurice Wilkes in Cambridge, and Alan Turing at the NPL to build their own stored-program machines. Within four years, stored-program computers were running in at least six countries.
What Came Next
The Baby proved the stored-program principle worked in silicon, or rather, in valves and phosphor. But the question of how to make such a machine learn had been sitting in a desk drawer in Donald Hebb's office at McGill University. In 1949 Hebb published The Organization of Behavior, proposing that synapses between neurons strengthen when the neurons fire together,a rule so simple and so powerful that it would underpin associative memory, Hopfield networks, and ultimately the weight-update rules of every modern neural network. That is the next story: .
References
- Williams, F.C. & Kilburn, T. (1948). Electronic Digital Computers. Nature, 162(4117), 487. The original one-column announcement of the Baby's existence.
- Kilburn, T. (1948). The University of Manchester Universal High-Speed Digital Computing Machine. Internal Report. University of Manchester. Kilburn's own technical description, written in 1948.
- Lavington, S. (1998). A History of Manchester Computers (2nd ed.). The British Computer Society. The definitive history of the Manchester machines from the Baby to the Atlas.
- Campbell-Kelly, M. & Aspray, W. (2004). Computer: A History of the Information Machine. Westview Press. Chapter 4 covers the stored-program race of 1946–1950.
- Napper, R.B.E. (1998). The Manchester Mark 1 Computers. In The First Computers: History and Architectures (ed. Rojas & Hashagen). MIT Press. Technical detail on the Baby's architecture and instruction set.
- O'Regan, G. (2012). A Brief History of Computing (2nd ed.). Springer. Chapter 5 situates the Baby in the broader context of early stored-program development.