Full Marks

GCSE Computer Science · Topic 8

Further data representation and quantitative skills

Further data representation and quantitative skills builds the calculations that often appear in exams.

We will add binary numbers, use binary shifts, and represent negative numbers with two's complement.

Then we calculate file sizes for text, images and sound, and compress data with run-length encoding and Huffman coding.

In this topic

  1. 8.1Binary addition and binary shiftsFree below · 69 questions
  2. 8.2Representing negative numbers: sign and magnitude, two's complementOpen in Full Marks · 61 questions
  3. 8.3Calculating file sizes for text, images and sound, and converting unitsOpen in Full Marks · 66 questions
  4. 8.4Compression in practice: run-length encoding and Huffman codingOpen in Full Marks · 68 questions

8.1 · Free notes

Binary addition and binary shifts

Diagram: Binary addition and binary shifts

Key points

In more detail

Practice

Binary addition and binary shifts: 10 questions

Pick an answer to check it, or open the answer for the explanation.

1. When adding three 1s in one column (two digits plus a carry), what is written and carried?

  1. Write 1, carry 0
  2. Write 0, carry 1
  3. Write 0, carry 0
  4. Write 1, carry 1
Show answer

D: Write 1, carry 1. 1+1+1 = 3, which is 11 in binary. The right-hand digit 1 is written in the column and the left-hand 1 is carried to the next column.

2. What is 00110101 + 00001110 in binary?

  1. 00111111
  2. 01000111
  3. 01000001
  4. 01000011
Show answer

D: 01000011. 53 + 14 = 67, which is 01000011. The column working with carries gives this result.

3. An 8-bit register adds 11001000 (200) and 01100100 (100). What happens?

  1. Overflow; the stored result 00101100 (44) is wrong
  2. The result 300 is stored correctly
  3. The result is rounded down to 255
  4. The result is stored as 00000000
Show answer

A: Overflow; the stored result 00101100 (44) is wrong. The true answer, 300, needs 9 bits. The ninth bit is lost, leaving 00101100 (44). This is an overflow error.

4. What is the denary value of 00000101 after a left shift of 3 places?

  1. 40
  2. 20
  3. 15
  4. 10
Show answer

A: 40. A left shift of 3 multiplies by 2³ = 8. 5 × 8 = 40, which is 00101000.

5. 01100100 (100) is shifted right by 2 places. What is the result in denary?

  1. 50
  2. 200
  3. 400
  4. 25
Show answer

D: 25. A right shift of 2 divides by 2² = 4. 100 ÷ 4 = 25, which is 00011001.

6. 00001111 (15) is shifted 1 place to the right. What is the denary result?

  1. 30
  2. 7.5
  3. 7
  4. 8
Show answer

C: 7. Right shifts give integer division. 00001111 becomes 00000111, which is 7. The remainder bit is lost.

7. Why is 10010011 shifted left 1 place in an 8-bit register not double the original value?

  1. The leading 1 is shifted out and lost
  2. Zeros are added on the left
  3. A left shift only adds 1
  4. The carry is added back on the right
Show answer

A: The leading 1 is shifted out and lost. The original is 147, and doubling gives 294, which is over 255. The most significant 1 is shifted out, leaving 00100110 (38).

8. Which shift multiplies an unsigned binary number by 16?

  1. Right shift of 4 places
  2. Right shift of 16 places
  3. Left shift of 4 places
  4. Left shift of 2 places
Show answer

C: Left shift of 4 places. Each place of left shift multiplies by 2. 2⁴ = 16, so 4 places are needed, shifting left.

9. What is 1 + 1 in a single binary column with no incoming carry?

  1. Write 0 and carry 1
  2. Write 1 and carry 1
  3. Write 0 and carry nothing
  4. Write 2
Show answer

A: Write 0 and carry 1. 1 + 1 = 2, which is 10 in binary. Write 0 in the column and carry 1 to the next column.

10. Add the 5-bit numbers 01101 and 00111. What is the result?

  1. 01100
  2. 10010
  3. 10110
  4. 10100
Show answer

D: 10100. 13 + 7 = 20, which is 10100 in 5 bits. The carries ripple across three columns.

Keep going in Full Marks

Full Marks has 69 questions on Binary addition and binary shifts (59 more than here), set out in practice levels. You also get notes and 3D models for all 4 subtopics of Further data representation and quantitative skills, plus games, timed exams and past papers.

On your exam board

All GCSE Computer Science topics