Binary Shifts (OCR GCSE Computer Science): Flashcards
📚Flashcards
Practise the cards
12 cards from this deck
ShowHide
Practise the cards
12 cards from this deck
Binary shifts
Binary shifts
Operations that move bits left or right
Left shift effect on value
Left shift effect on value
Increases value (multiplies by powers of 2)
Left shift by 1 place multiplies by
Left shift by 1 place multiplies by
2
Left shift by 2 places multiplies by
Left shift by 2 places multiplies by
4
Gaps filled in left shift
Gaps filled in left shift
0s on the right
Right shift effect on value
Right shift effect on value
Decreases value (divides by powers of 2)
Right shift by 1 place divides by
Right shift by 1 place divides by
2
Right shift by 2 places divides by
Right shift by 2 places divides by
4
Bits shifted out in right shift
Bits shifted out in right shift
Discarded/lost
Gaps filled in right shift
Gaps filled in right shift
0s on the left
00111100 (60) left shifted by 2
00111100 (60) left shifted by 2
11110000 (240)
00111100 (60) right shifted by 1
00111100 (60) right shifted by 1
00011110 (30)
