📁 Paper 2 · 3.3 Data Representation
3.3.4 Binary Arithmetic & Overflow
AQA 8525 · GCSE Computer Science · ~10 min read
Notes
──
Video
──
Worksheet
──
Quiz

Binary Addition Rules

Binary addition works like decimal addition, but with only two digits. The rules are:

CalculationBinary resultWrite downCarry
0 + 0000
0 + 1110
1 + 0110
1 + 11001
1 + 1 + 1 (with carry)1111

Worked Example — 8-bit Addition

Add 00110101₂ (53) and 00101110₂ (46):

carry: 0 0 1 1 0 0 0 0
  0 0 1 1 0 1 0 1
+   0 0 1 0 1 1 1 0
    0 1 1 0 0 0 1 1

Result: 01100011₂ = 99₁₀ ✓ (53 + 46 = 99)

Another Example

Add 00010111₂ (23) and 00001011₂ (11):

carry: 0 0 0 1 1 1 1 0
  0 0 0 1 0 1 1 1
+   0 0 0 0 1 0 1 1
    0 0 1 0 0 0 1 0

Result: 00100010₂ = 34₁₀ ✓ (23 + 11 = 34)

Overflow

Overflow occurs when the result of a binary calculation is too large to fit in the number of bits available. An 8-bit register can store a maximum of 11111111₂ = 255₁₀.

⚠️ Overflow Example

carry: 1 1 1 1 1 1 1 1 1
       1 1 1 1 1 1 1 1   (255₁₀)
+      0 0 0 0 0 0 0 1   (1₁₀)
1 0 0 0 0 0 0 0 0   ← 9 bits! The leading 1 is lost.
Stored as: 0 0 0 0 0 0 0 0 = 0₁₀ — WRONG!

The carry out from the 8th bit position is discarded, giving an incorrect result. This is called a carry overflow.

Why overflow matters

Overflow causes programs to produce incorrect results silently — the calculation appears to succeed, but the stored value is wrong. This has caused real-world disasters, including spacecraft failures from integer overflow errors.

How to avoid overflow

  • Use more bits (e.g. 16-bit or 32-bit integers instead of 8-bit)
  • Check the result before storing (compare with the maximum value)
  • Use programming language data types that handle large numbers automatically
Exam tip: To add binary numbers in an exam, always show the carry row. Overflow produces a result with more bits than the register holds — the extra (leftmost) bit is simply lost, giving an incorrect smaller value.
⚠️ Common Mistakes
  • Forgetting to carry — especially 1+1+1 = 11 in binary (write 1, carry 1)
  • Not writing the carry row — you'll lose track when multiple columns carry
  • Thinking overflow means the answer is negative — in unsigned binary, overflow wraps around to zero or a small positive value
Video coming soon

Key points

  • 1+1 in binary = 10 (write 0, carry 1); 1+1+1 = 11 (write 1, carry 1)
  • Always show the carry row when adding binary numbers
  • Overflow: result needs more bits than available; extra bits are lost
  • Max 8-bit value = 11111111 = 255; adding 1 causes overflow to 00000000
Click slide or press arrow keys to navigate
✍️

Worksheet — 3.3.4 Binary Arithmetic

8 questions · 20 marks

Q1State the binary result of each: 1+1, 1+1+1.[2]
✅ Mark scheme
Mark scheme
1+1 = 10 (write 0, carry 1) [1]; 1+1+1 = 11 (write 1, carry 1) [1].
Q2Add these 8-bit binary numbers: 00110011 + 00010100. Show the carry row.[3]
✅ Mark scheme
Mark scheme
Carry row shown [1]; working correct [1]; answer = 01000111 (=71₁₀; 51+20=71) [1].
Q3Add 01101010 + 00110101. Show your working and verify by converting to decimal.[3]
✅ Mark scheme
Mark scheme
Carry shown [1]; answer = 10011111 [1]; verification: 106+53=159=10011111 ✓ [1].
Q4Define 'overflow' in the context of binary arithmetic.[2]
✅ Mark scheme
Mark scheme
Overflow occurs when the result of a calculation is too large to fit in the available number of bits [1]; the extra (most significant) bits are lost/discarded, producing an incorrect result [1].
Q5An 8-bit register currently holds 11111110. The value 3 (00000011) is added to it. What is stored in the register? Explain what has happened.[3]
✅ Mark scheme
Mark scheme
11111110 + 00000011 = 100000001; the 9th bit (carry out) is discarded [1]; 8 bits stored = 00000001 [1]; overflow has occurred — the true answer (257) is too large for 8 bits, so the result wraps around incorrectly to 1 [1].
Q6What is the maximum value that can be stored in an 8-bit register, and what happens when you add 1 to it?[2]
✅ Mark scheme
Mark scheme
Maximum = 11111111 = 255₁₀ [1]; adding 1 causes overflow — the result would be 100000000 (9 bits), but only 8 bits are stored, so 00000000 = 0 is stored (incorrect) [1].
Q7Give two ways a programmer can prevent overflow errors.[2]
✅ Mark scheme
Mark scheme
Any two: use a larger data type (more bits, e.g. 16-bit or 32-bit integer) [1]; check the value before adding to ensure it won't exceed the maximum [1]; use a language that automatically handles large numbers [1].
Q8Add these two 8-bit numbers in binary. Does overflow occur? 10110000 + 01100000. Show working.[3]
✅ Mark scheme
Mark scheme
Carry shown [1]; 10110000+01100000=100010000; 9 bits, carry out = 1 [1]; overflow HAS occurred — result (272₁₀) exceeds 255, stored as 00010000 (16₁₀) [1].
Check your answers above.
Topic Quiz
Q 1 of 10
You scored
out of 10
Card 1 of 4
Click to flip
🎉
All done!
TermDefinition
🎯

Mini Test — 3.3.4 Binary Arithmetic

Timed exam conditions.

  • 8 questions · 10 minutes
  • 5 MCQ + 3 short answer
← 3.3.3 Units of Information
27 of 57 · AQA 8525
3.3.5 Character Encoding →