The Counter That Walks the Processor Through Addresses
Before level 16 the game offers a short interactive intro: you press WRITE and watch a number in a closed loop grow by one with every press. This page tells the same story in text.
Experiment: a number that grows
In the middle of the circuit is a loop: a register holds a number, the ALU adds 1 to it, and the result goes back into the register's input. Press WRITE and watch the lamp: 0, 1, 2, 3… Each press moves the number exactly one step. There is no reset and no return to zero — the number only grows.
Predict: what the edge writes
Suppose the register now holds 3, and the ALU has already computed 3+1. A WRITE edge arrives — what ends up in the register? Four. While nobody touches the register, the ALU keeps recomputing the same thing: "current plus one". The edge is the moment of writing: it "clicks" the loop, and the ready value lands in the register. Before the edge, only the old number is visible outside.
The rule: register + 1 back = counter
The closed loop "hold → add 1 → write back" is called a counter. The feedback here works just like in the latch from level 10: there, two gates fed each other signals and stored one bit; here, a ring of a register and an ALU stores a number and steps it forward. The register output is an address that grows tick by tick.
Where it is used
On level 16 you will build the program counter (PC). A program sits in memory at addresses, and the processor runs it step by step: one tick — one instruction, and the PC steps forward on its own, bringing the processor to the next one. Remove this loop, and the processor reads the same cell forever.