A number base (or radix) defines how many unique digits a positional number system uses. Each digit position represents a power of the base.
| Base | Name | Digits used | Used in computing for |
|---|---|---|---|
| 2 | Binary | 0, 1 | All internal computer storage and processing |
| 8 | Octal | 0–7 | Unix file permissions; compact binary notation |
| 10 | Decimal | 0–9 | Human-readable numbers |
| 16 | Hexadecimal | 0–9, A–F | Memory addresses, colour codes, machine code |
In a base-n system, each digit position has a value of n raised to a power:
Binary: 1011₂ = 1×2³ + 0×2² + 1×2¹ + 1×2⁰ = 8 + 0 + 2 + 1 = 11₁₀ Hexadecimal: 2A₁₆ = 2×16¹ + A×16⁰ = 32 + 10 = 42₁₀
Binary is the foundation of all computing — transistors have two states (on/off) mapping to 1 and 0.
Divide repeatedly by 2, recording remainders from bottom to top:
Convert 43₁₀ to binary: 43 ÷ 2 = 21 remainder 1 21 ÷ 2 = 10 remainder 1 10 ÷ 2 = 5 remainder 0 5 ÷ 2 = 2 remainder 1 2 ÷ 2 = 1 remainder 0 1 ÷ 2 = 0 remainder 1 Read remainders upward: 43₁₀ = 101011₂
101011₂ = 1×32 + 0×16 + 1×8 + 0×4 + 1×2 + 1×1
= 32 + 0 + 8 + 0 + 2 + 1 = 43₁₀
Hexadecimal is a compact way to represent binary — each hex digit represents exactly 4 bits (a nibble).
| Hex | Decimal | Binary (4-bit) |
|---|---|---|
| 0 | 0 | 0000 |
| 5 | 5 | 0101 |
| 9 | 9 | 1001 |
| A | 10 | 1010 |
| B | 11 | 1011 |
| F | 15 | 1111 |
Binary to Hex — group bits in 4s from the right: 10110101₂ → 1011 | 0101 → B | 5 → B5₁₆ Hex to Binary — expand each digit to 4 bits: 3F₁₆ → 0011 | 1111 → 00111111₂
B5₁₆ = 11×16 + 5×1 = 176 + 5 = 181₁₀
Convert 255₁₀ to hex: 255 ÷ 16 = 15 remainder 15 → F 15 ÷ 16 = 0 remainder 15 → F Read upward: 255₁₀ = FF₁₆
0xFF3C10), colour codes (#FF6600), MAC addresses, machine code output8 questions · instantly marked · AQA 7517 standard
| Term | Definition |
|---|
10 questions · 10 minutes