Binary arithmetic, shifts and hexadecimal
플레이하며 배우기
이 문제들을 풀어 에너지를 얻은 뒤 낚시하고 탐험하세요. 계정이 필요 없어요.
교육자를 위해: Binary arithmetic, shifts and hexadecimal(Computer Science, Data Representation)을(를) 위한 바로 쓸 수 있는 수업 슬라이드, 복습 노트 — 수업에 사용하거나, 학습자들이 실시간 게임으로 즐기는 인터랙티브 클래스 활동으로 진행하세요.
수업 노트
Binary addition
- Rules: 0+0 = 0; 0+1 = 1; 1+1 = 10 (write 0, carry 1); 1+1+1 = 11 (write 1, carry 1).
- Example: 0101 + 0011 = 1000 (5 + 3 = 8).
- Overflow: if the result needs more bits than are available (e.g. an 8-bit register gets a 9th bit), the extra bit is lost, giving a wrong answer.
Adding unsigned values
Binary shifts
- A left shift moves bits left, filling with 0s: it multiplies an unsigned value by 2 for each place, provided no significant bit is lost. 00001100 (12) shifted left 2 = 00110000 (48).
- A right shift moves bits right, filling with 0s: it divides by 2 (rounding down) for each place. 00001100 shifted right 1 = 00000110 (6).
- Bits shifted off the end are lost.
Unsigned eight-bit shifts
Hexadecimal
- Hexadecimal (base 16) uses digits 0-9 and A-F (A=10 ... F=15).
- Binary to hex: split into 4-bit groups (nibbles). 1010 1111 → A F → AF. Hex to binary: convert each digit: 3C → 0011 1100.
- Hex to denary: 3C = 3×16 + 12 = 60. Denary to hex: 255 = FF.
Four bits per hex digit
Why hex?
- Hex is shorter and easier for humans to read and write than long binary: colour codes (#FF0000), memory addresses, MAC addresses and error codes.
슬라이드
연습 문제
무료 미리 보기 — 33개 중 8개 문제. 가입하면 전부 볼 수 있어요.
1.What base does hexadecimal use?
Easy- A16
- B10
- C2
- D8
2.What is binary 1 + 1?
Easy- A10
- B2
- C11
- D0
3.What does overflow mean?
Easy- Athe result is too big for the bits available
- Bthe result is zero
- Cthe result is negative
- Dthe loop ends
4.What is F in denary?
Easy- A15
- B16
- C14
- D10
5.For an unsigned binary value, with no significant bit lost, what is the effect of a one-place left shift?
Easy- Adoubles the value
- Bhalves the value
- Cadds 1
- Dsubtracts 1
6.What is 00000110 shifted left 1?
Easy- A00001100
- B00000011
- C00001010
- D00001000
7.What is 00001000 shifted right 2?
Easy- A00000010
- B00100000
- C00000100
- D00000001
8.What is 0011 + 0110 in binary?
Easy- A1001
- B1010
- C0111
- D1000
기출 문제
이 주제의 기출 문제 연습이 곧 나와요.
곧 출시
