Bytesize CS

Binary addition

Add the binary numbers. Work from right to left, carrying as you go. Click the answer bits, or type 0 and 1. You can use the carry boxes for your working.

Score 0 / 0 Streak 0 Best 0

How to add binary numbers

Start with the right-hand column and work left. In each column, add the bits and any carry:

  1. 0 in total: write 0.
  2. 1 in total: write 1.
  3. 2 in total (binary 10): write 0 and carry 1.
  4. 3 in total (binary 11): write 1 and carry 1.

Adding three numbers: a column can add up to 4 (binary 100) or 5 (binary 101). Write the last bit, carry 0 into the next column and carry 1 into the column after that. A carry is only ever 0 or 1. That is why three-byte sums have two carry rows: one for carries from the next column, and one for carries from two columns away. A column can receive both.

Overflow: if the answer needs more bits than the register can hold (more than 8 bits for a byte, or 4 for a nibble), an overflow error happens. The extra bit on the left is lost, so the stored result is wrong.