Level:
Correct: 0
Incorrect: 0
Marks: 0/0
Exam Practice
Course:
Topics:
AQA GCSE Computer Science (Paper 2) Smart practice A mixed round aimed at your weak spots
Unit 1
3.3 Fundamentals of data representation
Unit 2
3.4 Computer systems
Unit 3
3.5 Fundamentals of computer networks
Unit 4
3.6 Cyber security
Fundamentals of cyber security; cyber security threats
Cyber security, its threats and penetration testing
Methods to detect and prevent cyber security threats
Detecting and preventing cyber security threats
Unit 5
3.7 Relational databases and SQL
Unit 6
3.8 Ethical, legal and environmental impacts
Ethical, legal and environmental impacts
Ethical, legal and environmental impacts of technology
Avg
score:
–
Topics
done:
0/22

Binary addition and binary shifts

Practise 30 exam-style questions on Binary addition and binary shifts for AQA GCSE Computer Science (Paper 2). Write your answer as you would in the exam and get it marked in seconds against the mark scheme, point by point, with the Study Helper on hand if you get stuck.

  • 30 questions
  • 1–4 marks each
  • Instant marking
  • No sign-up needed
20 questions, marked as you go

Sample questions with model answers

Here are 4 of the questions in this topic, each with a model answer, an explanation of why it earns the marks and the mark scheme an examiner would use.

Question 1

1 mark

The figure shows an 8-bit binary number before and after a logical left shift of two places.

State the 8-bit result of the shift.

Two 8-bit registers, each drawn as a row of 8 boxes, with the place values 128, 64, 32, 16, 8, 4, 2, 1 above the columns. Row 1 (labelled "Before"): 00010111. Between rows 1 and 2 an arrow points left, labelled "Logical left shift of 2 places". Row 2 (labelled "After"): all 8 boxes blank.

Model answer

01011100 - every bit moves two places to the left, the two left-most bits (00) are lost and two 0s enter on the right.

Explanation

In a logical left shift every bit moves the stated number of places to the left; the bits that move out of the left-hand end are lost and 0s fill the gaps on the right. Here 00 is lost and 00 is added, so 00010111 (23) becomes 01011100 (92), which is 23 × 4. Filling the gaps with 1s or shifting the wrong way are the usual mistakes.

Mark scheme
  1. 1 mark

    01011100

    Mark is for AO2 (apply). Correct answer with no working scores full marks. A. 1011100 (leading zero omitted). I. Spaces between bits. R. 92 (decimal) on its own.

Question 2

2 marks

A school sells tickets for its play on three evenings. The number of tickets sold each evening is stored as an 8-bit binary number: 00101101 on Wednesday, 01001010 on Thursday and 00010110 on Friday.

Add the three binary numbers to find the total number of tickets sold. Give your answer in binary.

Model answer

00101101
01001010
+ 00010110
The 4 column is 1 + 0 + 1 + carry 1 = 11 (write 1, carry 1) and the 8 column is 1 + 1 + 0 + carry 1 = 11 (write 1, carry 1). There are carries into the 4, 8, 16, 32, 64 and 128 columns.
Total: 10001101

Explanation

With three numbers, count the 1s in each column including any carry: one 1 gives 1, two 1s give 10 (write 0, carry 1) and three 1s give 11 (write 1, carry 1). Here the 4 and 8 columns each contain three 1s once the carry is counted. Check in decimal: 45 + 74 + 22 = 141 = 128 + 8 + 4 + 1. Treating three 1s as 10 instead of 11 is the usual mistake.

Mark scheme
  1. 1 mark

    1000 as the left-most four bits

    All marks AO2 (apply). The full answer is 10001101. Mark the two halves of the answer separately. If fewer than eight bits are given, read the bits from right to left. Correct answer with no working scores full marks. I. Spaces between bits.

  2. 1 mark

    1101 as the right-most four bits

    R. An answer given only in decimal (141).

Question 3

2 marks

A games company is writing software for a handheld console whose processor can carry out binary shifts very quickly.

Describe two different situations in the game software where a binary shift could be used.

Model answer

When a player collects a power-up, their score for that round could be doubled by shifting it one place to the left. When a character walks through mud, their speed could be halved by shifting it one place to the right.

Explanation

Binary shifts can only multiply or divide by powers of 2, so each situation must involve doubling, halving, or multiplying or dividing by 4, 8, 16 and so on. Saying 'to do calculations', or giving an example such as multiplying by 3 or dividing by 10, does not score, because a single shift cannot do those. A left shift multiplies and a right shift divides (rounding down).

Mark scheme
  1. 1 mark

    a situation where a value in the game is multiplied or divided by a power of 2 (2, 4, 8, 16 ...), e.g. doubling a player's score in a bonus round (left shift) // halving a character's speed (right shift) // multiplying the points for a gem by 4 // dividing a screen position by 8 or 16 to find the tile it is on

    All marks AO2 (apply). 1 mark for each different situation, up to 2. Each situation must state or clearly imply multiplying or dividing by a power of 2. R. multiplying or dividing by a number that is not a power of 2 (e.g. multiplying by 3, dividing by 10). NE. 'to do calculations' // 'to make the game faster'.

  2. 1 mark

    a second, different situation where a value is multiplied or divided by a power of 2

    Do not award both marks for the same situation given twice (e.g. doubling the score and doubling the score again). Two different multiplying situations, or two different dividing situations, can score both marks.

Question 4

3 marks

Sam says: 'A logical right shift of one place always halves a binary number exactly.'

Using the 8-bit binary number 01001101 as an example, explain whether Sam is correct.

Model answer

Sam is not correct. 01001101 is 77 in decimal. Shifting it one place right gives 00100110, which is 38, but half of 77 is 38.5. The right-most bit, a 1, was shifted out and lost, so the result was rounded down. A right shift of one place only halves a number exactly when its right-most bit is 0, which means the number is even.

Explanation

A right shift halves the value of every bit that stays in the register, but the bit that falls off the right-hand end is lost. If that bit is a 1, the result is half the number rounded down. Comparing the values in decimal (77 ÷ 2 = 38.5, but the shift gives 38) is the clearest way to show this.

Mark scheme
  1. 1 mark

    the result of the shift is 00100110 // 38

    All marks AO2 (apply). A. 100110.

  2. 1 mark

    half of 01001101 (77) is 38.5, so the result is not exactly half // so Sam is not (always) correct

    The conclusion must be supported by the values (77 and 38 or 38.5). NE. 'Sam is wrong' on its own.

  3. 1 mark

    because the right-most bit (a 1) is shifted out and lost // the result is rounded down // a right shift only halves exactly when the right-most bit is 0 / the number is even

    A. 'the 1 in the 1s column is lost'.

Ready to try the rest? Every answer you write is marked against the mark scheme, so you can see exactly where the marks are.

Study Helper Hints first, answers after you try

Stuck on this one? Ask for a hint and I’ll point you in the right direction, without giving the answer away. Once you’ve checked your answer, I’ll show you how the marks are awarded.