Binary Shifts (CIE IGCSE Computer Science)

Revision Note

Test Yourself
Becci Peters

Expertise

Computer Science

Binary Shifts

  • A binary shift is the term used for multiplying or dividing in binary
  • A binary shift moves all the bits in a binary number a certain number of positions to the left or right
  • When performing a logical binary shift to the left, the bits shifted from the end of the register are lost, and zeros are shifted in at the opposite end
  • When performing a logical binary shift to the right, the bits shifted from the beginning of the register are lost, and zeros are shifted in at the opposite end
  • When performing a logical binary shift, the positive binary integer is multiplied or divided according to the shift performed. A shift to the left is equivalent to multiplication by a power of 2, while a shift to the right is equivalent to division by a power of 2
  • When performing a logical binary shift, the most significant bit(s) or least significant bit(s) are lost, depending on the direction of the shift

Binary shift walkthrough:

  • E.g. shifting the binary number 11001100 to the left by two positions gives 00110000. The two bits shifted from the end are lost, and two zeros are shifted in at the opposite end
  • E.g. shifting the binary number 11001100 to the right by two positions gives 00110011. The two bits shifted from the beginning are lost, and two zeros are shifted in at the opposite end
  • E.g. shifting 11001100 to the left by two positions, is multiplying it by 22, or 4. The result is 00110000, which is equal to 4 times the original value
  • Shifting the binary number 11001100 to the right by two positions, is dividing it by 22, or 4. The result is 00110011, which is equal to the original value divided by 4

Exam Tip

  • Make sure you’ve got the same number of bits in your answer as there were in the question. Check your answer by converting the binary number to denary, working out your answer and converting it back again. Make sure to label this checking so the examiner knows it isn’t part of your working out

You've read 0 of your 0 free revision notes

Get unlimited access

to absolutely everything:

  • Downloadable PDFs
  • Unlimited Revision Notes
  • Topic Questions
  • Past Papers
  • Model Answers
  • Videos (Maths and Science)

Join the 100,000+ Students that ❤️ Save My Exams

the (exam) results speak for themselves:

Did this page help you?

Becci Peters

Author: Becci Peters

Becci has been a passionate Computing teacher for over 9 years, teaching Computing across the UK helping to engage, interest and develop confidence in the subject at all levels. Working as a Head of Department and then as an educational consultant, Becci has advised schools in England, where her role was to support and coach teachers to improve Computing teaching for all. Becci is also a senior examiner for multiple exam boards covering GCSE & A-level. She has worked as a lecturer at a university, lecturing trainee teachers for Computing.