Binary Addition, Shifts and Two's Complement
How a register adds, why an answer too large for its bits overflows, how shifting multiplies or divides and loses bits, and why flipping every bit and adding one makes a negative number.
↺
Where does a column's extra 1 go?
Step 1 of 3 · Add both 1s: tap a Write digit, or its coin to write and carry.
Start
Goal
Plate
Carry
A
+ B
R
Trayoutside R · first out →
Empty
Carry
outside R
outside R
Overflow lamp unsigned additionNot run
BFlipped bits: one's complement
Before—
After—
Hopper0
LeverDrag Lever, or tap an end
Hopper wireConnected to 0
Your pulls
The chute and tray keep lost bits visible; real register bits are simply lost. The lamp labels unsigned or signed addition overflow. Gate timing and other processor flags are not shown.