Show understanding of different number systems
1.1 Data Representation – Understanding Number Systems
Binary (Base‑2)
Binary is the language computers speak. It uses only two digits: 0 and 1. Think of it as a light switch – off (0) or on (1). Every piece of data is ultimately a string of these bits.
1011₂.
Conversion to Decimal: Multiply each bit by 2 raised to its position (starting from 0 on the right) and sum.
- Write the binary number:
1101₂ - Positions: 3 2 1 0
- Values: 2³ 2² 2¹ 2⁰
- Multiply: 1×8 + 1×4 + 0×2 + 1×1 = 13
- Result:
1101₂ = 13₁₀
| Binary | Decimal |
|---|---|
| 0000₂ | 0₁₀ |
| 0011₂ | 3₁₀ |
| 1010₂ | 10₁₀ |
Octal (Base‑8)
Octal uses digits 0–7. It’s like grouping binary bits in threes. Computers sometimes use octal for compactness, especially in older systems.
0, e.g. 075₈.
Conversion Example: 17₈ → 1×8¹ + 7×8⁰ = 15₁₀.
Hexadecimal (Base‑16)
Hexadecimal uses digits 0–9 and letters A–F (A=10, B=11, …, F=15). It’s popular for representing memory addresses and colours in web design (e.g. #FF5733).
0x or a trailing ₁₆, e.g. 0x1A₁₆ or 1A₁₆.
Conversion Example: 2F₁₆ → 2×16¹ + 15×16⁰ = 47₁₀.
| Hex | Decimal |
|---|---|
| 0₁₆ | 0₁₀ |
| A₁₆ | 10₁₀ |
| 1F₁₆ | 31₁₀ |
Decimal (Base‑10)
Decimal is the system we use every day. It has ten digits (0–9). Computers convert everything to decimal for human readability.
Key Takeaways for the Exam
- Know how to convert between binary, octal, decimal, and hexadecimal.
- Remember the base notation:
101₁₀,101₂,101₈,0x101₁₆. - Practice writing conversion tables; they help with quick mental calculations.
- Use the “powers of the base” method for conversions (e.g., 2ⁿ, 8ⁿ, 16ⁿ).
- Check your work by converting back to the original base.
Quick Conversion Cheat Sheet
| Binary | Octal | Decimal | Hex |
|---|---|---|---|
| 1101₂ | 15₈ | 13₁₀ | D₁₆ |
| 1010₂ | 12₈ | 10₁₀ | A₁₆ |
| 11111111₂ | 377₈ | 255₁₀ | FF₁₆ |
Revision
Log in to practice.