Perform logical right and repeated shifts
Apply right and repeated logical shifts, explaining zero-fill, lost bits and division by powers of two.
Exam scope and assessment notes
This sequence follows Cambridge IGCSE Computer Science 0984, 2026–2028 syllabus Version 4. It covers subject content sections 1.1–1.3 only. The separately published 2029–2031 syllabus is not mapped here. Practice is original, self-checked and does not award an official Cambridge grade. Full timed papers and human subject-teacher review remain outstanding. Cambridge states that 0984 has the same 2026–2028 subject content as 0478, with 9–1 grading. In June and November, Cambridge lists 0984 in Administrative zone 3 and for centres in Oman and the UAE. Confirm availability for your centre and exam series with Cambridge International. The separately published 2029–2031 syllabus changes to Python 3 only and removes pseudocode; this 2026–2028 route does not cover those changes.
Before you begin
- No programming language is required. Be comfortable with place value and multiplication; each lesson introduces the computer-science notation it uses.
Work on paper. Try each question before revealing help, and explain why your method works.
Quick readiness check
Which bit is discarded in a logical right shift?
What you will learn
- Perform a logical right shift on a positive 8-bit integer
- Perform multiple shifts in sequence
- Explain the effect of discarded least significant bits
A right shift inserts zeros on the left
Move every bit one place right; the rightmost bit is discarded and a zero enters at the left. Repeat for each shift rather than jumping to a guessed result.
Apply and check the rule
For an unsigned positive integer, one right shift divides by two and discards any remainder. Two right shifts divide by four, again discarding low bits. The result is integer division, not a fractional binary value.
Pause and explain
What does two-place logical right shifting do to a positive integer when considered arithmetically?
Worked example
Shift 00101101₂ right twice.
Show the worked solution
- After one shift: 00010110; the final 1 is lost.
- After a second: 00001011; another 0 is lost.
- 45 divided by 4 gives integer result 11.
Answer 00001011₂ (11)
Try a topic test
Choose Easy, Normal or Difficult. Save your answers and open worked review after finishing.
Test this topic →From guided practice to a new situation
Write your answer and reasoning first. Use a hint only if you are stuck. The model solution is for self-checking; your written work is not automatically marked.
Shift 10010010₂ right once.
Give me a hint
Drop the rightmost bit; insert zero at the left.
Compare my reasoning
- Discard the final 0.
- Move the remaining bits one place right.
- The value 146 becomes 73.
01001001₂ (73)
Look for these in your work
- Leading zero inserted
- Rightmost bit discarded
- Value halves
Shift 01100101₂ right twice.
Give me a hint
Write the intermediate pattern after the first shift.
Compare my reasoning
- First: 00110010; discard the final 1.
- Second: 00011001; discard the final 0.
- 101 divided by 4 gives 25.
00011001₂ (25)
Look for these in your work
- Intermediate pattern correct
- Final pattern correct
- Remainder handling understood
A sensor value 173 is right-shifted twice before display. State the binary result and what happened to the discarded information.
Give me a hint
Convert to eight-bit binary, then shift one position at a time.
Compare my reasoning
- 173 is 10101101₂.
- After two right shifts: 00101011₂.
- The two least significant bits were discarded; 173/4=43 remainder 1.
00101011₂ (43). The original lower two bits are lost, including the remainder 1.
Look for these in your work
- Starting pattern correct
- Two shifts shown
- Lost bits/remainder explained
Common mistakes
- Wrapping a lost bit around to the left
- Forgetting that a right shift discards a remainder
What can you explain now?
What is 00010111₂ after one logical right shift?
Compare with the explanation
00001011₂
The last 1 is discarded and a zero enters on the left; 23 divided by 2 gives 11 remainder 1.
After trying it yourself, choose your next review. This is your self-assessment.
Your review choice appears on Today. Sign in to sync it across devices.
Make it stick
Why can a right shift of an odd value change its value by more than an exact division by two?
If you needed the solution, close it and solve the problem again from a blank page. A correct answer is stronger when you can explain the reason for each step.