Worked solution from the Data representation Paper 1 Computer Systems booklet, Part 1 of 3.
Write: B (base 2) [1]
Use place values 128, 64, 32, 16, 8, 4, 2, 1.
50 = 32 + 16 + 2 = 00110010 [1]
102 = 64 + 32 + 4 + 2 = 01100110 [1]
221 = 128 + 64 + 16 + 8 + 4 + 1 = 11011101 [1]
Write 78 in binary, flip the bits, then add 1.
78 = 01001110
Flip: 10110001
Add 1: 10110010
Method shown (binary, flip, add 1) [1]
Register: 10110010 [1]
Add from the right, carrying 1 when the sum is 2 or more.
| Bit position | 7 | 6 | 5 | 4 | 3 | 2 | 1 | 0 |
|---|---|---|---|---|---|---|---|---|
| First number | 0 | 0 | 1 | 1 | 0 | 0 | 1 | 1 |
| Second number | 0 | 1 | 1 | 0 | 0 | 0 | 0 | 1 |
| Carry in | 1 | 1 | 0 | 0 | 0 | 1 | 1 | 0 |
| Answer | 1 | 0 | 0 | 1 | 0 | 1 | 0 | 0 |
Working with the carries shown correctly [1]
First four bits 1001 [1]
Last four bits 0100, so the answer is 10010100 [1]
The result of the addition is bigger than 255 (the largest value 8 bits can hold) [1]
It needs more than 8 bits, but the register only has 8 bits [1]
▶ Topic lesson
A lesson on this topic · by Mr Bulmer's Learning Zone. Tap the picture to open it on YouTube.
Solutions follow the official Cambridge mark schemes; marks are shown in grey. Videos are from other YouTube channels. Paper codes read component / series / year: M/J = May/June, O/N = October/November. Past-paper questions © UCLES, reproduced for classroom practice.