Preparing for My Final Exam… Number Systems: Decimal, Binary, Octal, and Hexadecimal
From Decimal to …
Binary (example: 45₁₀ → ?₂)
Rule: Repeatedly divide by 2 and record the remainder each time. Read remainders bottom → top.
Read up: 1 0 1 1 0 1 → 45₁₀ = 101101₂
Octal (example: 45₁₀ → ?₈)
Divide by 8 instead:
Read up → 55₈
45₁₀ = 55₈
Hexadecimal (example: 45₁₀ → ?₁₆)
Divide by 16:
Read up → 2 D → 45₁₀ = 2D₁₆
From Binary to …
Decimal (example: 110101₂ → ?₁₀)
Multiply each place value by a power of 2 and sum:
- 1×32 + 1×16 + 0×8 + 1×4 + 0×2 + 1×1
= 32 + 16 + 0 + 4 + 0 + 1 = 53
110101₂ = 53₁₀
Octal (example: 110101₂ → ?₈)
Group 3 bits from the right, convert each group to a single octal digit.
- 110101 → (110)(101) → 6, 5 → 65₈
- 1⋅4+1⋅2+0⋅1=4+2+0=6
- 1⋅4+0⋅2+1⋅1=4+0+1=5
110101₂ = 65₈
Hexadecimal (example: 110101₂ → ?₁₆)
Group 4 bits from the right (pad left with zeros if needed).
- 110101 → 0011 0101 → 3, 5 → 35₁₆
- 0011₂ = 0×8+0×4+1×2+1×1=30×23+0×22+1×21+1×20=3
- 0101₂ = 0×8+1×4+0×2+1×1= 50×23+1×22+0×21+1×20=5 → 35₁₆
- 110101₂ = 35₁₆
From Octal to …
Decimal (example: 745₈ → ?₁₀)
Use powers of 8:
- 7×64 + 4×8 + 5×1
= 448 + 32 + 5 = 485
745₈ = 485₁₀
Get Lia’s stories in your inbox
Join Medium for free to get updates from this writer.
Binary (example: 756₈ → ?₂)
Convert each octal digit to 3-bit binary:
- 7→111, 5→101, 6→110 → 111101110₂
756₈ = 111101110₂
Hexadecimal (example: 756₈ → ?₁₆)
Go via binary, then group in 4 bits:
- 756₈ → 111101110₂ → pad left: 0001 1110 1110
- 0001→1, 1110→E, 1110→E → 1EE₁₆
- 0001₂ = 0×8+0×4+0×2+1×1= 1
- 1110₂ = 1×8+1×4+1×2+0×2=14 → E
- 1110₂ = 14 → E
- 756₈ = 1EE₁₆
From Hexadecimal to …
Decimal (example: 2F₁₆ → ?₁₀)
Use powers of 16 (F = 15):
- 2×2=16+ 15×1 = 32 + 15 = 47
2F₁₆ = 47₁₀
Binary (example: 2F₁₆ → ?₂)
Each hex digit → 4-bit binary:
- 2→0010, F→1111 → 0010 1111₂ (leading zeros optional → 101111₂)
2F₁₆ = 00101111₂
Octal (example: 2F₁₆ → ?₈)
Hex → Binary → group 3 bits:
- 2F₁₆ → 0010 1111₂ → group: 000 101 111 → 0, 5, 7
- 000=>0×4+0×2+0×1=0
- 101=>1×4+0×2+1×1=4+0+1=5
- 111=1×4+1×2+1×1=4+2+1=7
- drop leading 0 → 57₈
2F₁₆ = 57₈










