You got 87 in maths, and your school’s computer has saved it. But that computer has no digit 8 and no digit 7. Inside it are tiny switches, and a switch can only be off or on. So it has just two symbols to write with, 0 and 1. How can it store 87, or a bus fare, or every photo on a phone?
The answer is an idea you already use: a digit’s worth depends on its place. Change how many things make a bundle, and the same number gets a new way of being written. By the end of this unit you can write any number with only two digits, or five, and read it back. In Back to the 87 you will write what the computer stores.
2.0 Review
The numbers 0, 1, 2, 3, 4, … are the whole numbers: the counting numbers with 0 added. There is only one set of them, but there are many ways to write them. This unit is about those ways, starting with the one you know.
Here is 1256 in a place value table. Each digit sits under what it counts:
| Thousand | Hundred | Ten | One |
|---|---|---|---|
| 1 | 2 | 5 | 6 |
So 1256 means 1 thousand, 2 hundreds, 5 tens and 6 ones. Written out, that is its expanded form:
Any whole number can be written in expanded form with 10 and its powers. A number system whose places are one, ten, hundred, thousand, … (that is ) is the decimal number system. It uses ten digits, 0, 1, 2, 3, 4, 5, 6, 7, 8 and 9, so its base is 10. It is also called the Hindu-Arabic numeration system.
For example:
In 4075, what is the 7 worth?
Pick an answer to see why.
Why does a digit never go above 9? Because ten of anything is packed into one bundle of the next size. That is all a base is: how many make a bundle. Ten is only one choice.
2.1 Binary number system
2.1.1 Introduction to the binary number system
The bulb glows when the switch is ON and stops when it is OFF. Write ON as 1 and OFF as 0, and one switch can store one digit. A chip holds a huge number of tiny electronic switches, so computers write everything with these two digits. Numbers written with only 0 and 1 are in the binary number system (“bi” means two, as in a bicycle’s two wheels). It uses two digits, so its base is 2.
How do you count with only two digits?
| Binary | Decimal | Binary | Decimal |
|---|---|---|---|
| 1 | 1 | 110 | 6 |
| 10 | 2 | 111 | 7 |
| 11 | 3 | 1000 | 8 |
| 100 | 4 | 1001 | 9 |
| 101 | 5 | 1010 | 10 |
In the decimal system we use ten digits; in the binary system only two, 0 and 1. We count in binary as 0, 1, 10, 11, 100, 101, 110, …
Counting works as it does in decimal. When 9 is full, the next number is 10: back to 0 and carry 1. In binary the digit 1 is already full, so the carry comes at once: after 1 comes 10, and after 11 comes 100, as 99 goes to 100.
Which number comes straight after 1011 when you count in binary?
Pick an answer to see why.
2.1.2 The binary number system and its expansion
| Number | 32 | 16 | 8 | 4 | 2 | 1 |
|---|---|---|---|---|---|---|
| 1₂ | 1 | |||||
| 10₂ | 1 | 0 | ||||
| 11₂ | 1 | 1 | ||||
| 100₂ | 1 | 0 | 0 | |||
| 100101₂ | 1 | 0 | 0 | 1 | 0 | 1 |
The small 2 after a number is its suffix: it says the number is in base 2. Without it, 101 would be a hundred and one. With the table we can write binary numbers in expanded form:
and the longest of them:
As the decimal system’s places are one, ten, hundred, thousand, … (), the binary system’s are one, two, four, eight, sixteen, … (). A binary number is written with the suffix 2, as in 10₂ and 1001₂.
In 1000₂, what is the 1 worth?
Pick an answer to see why.
2.1.3 Conversion from the decimal number system to binary
To write a number in binary, we must find which place values add up to it.
For a big number, hunting for powers is slow. There is a quicker way that always works: divide by 2 again and again.
Why would dividing help? Think of 27 pens. Divide by 2, and you pack them in pairs: 13 pairs, 1 pen left over. That 1 can’t be packed, so it is the digit of the ones place. Now pack the 13 pairs in twos: 6 fours, 1 pair left over. That is the digit of the twos place. Keep going. Each remainder is the digit of the next place, and the first one is the rightmost digit. Figure 2.2 shows it.
In base 10 a remainder can be 0 to 9; in base 2 it can only be 0 or 1. That is why dividing by 2 gives nothing but binary digits.
So, to change a decimal number to binary:
- Divide the number by 2, and write the remainder at the right.
- Divide the quotient by 2 in the same way, and keep going until the quotient is 0.
- Write the remainders from bottom to top.
Now convert 29 in the same way. You should get 11101₂, as in Activity 4.
Back to the 87
Now you can answer the question this unit began with. The computer stores 87 as 1010111.
Seven switches do it: ON, OFF, ON, OFF, ON, ON, ON, as in the widget at the top of this unit. A photo or a song is stored the same way, as a very long row of such numbers. Your mark takes seven digits instead of two, but that costs the computer nothing: it has plenty of switches, and it flips them billions of times a second.
2.1.4 Conversion from the binary number system to decimal
Expand 100101₂ in powers of 2 and simplify:
We don’t write the base 10 on 37: a number with no suffix is understood to be decimal.
To change a binary number to decimal, write it in expanded form in powers of 2, then simplify. The zeros add nothing, so the quick way is to add the place values under the 1s.
Which is the biggest number you can write with eight binary digits?
Pick an answer to see why.
2.2 Quinary number system
2.2.1 Introduction to the quinary number system
Why stop at 2? Any whole number above 1 can be a base. Five is the one a hand gives you: the quinary number system has base 5 and the five digits 0, 1, 2, 3 and 4.
| Quinary | Decimal | Quinary | Decimal |
|---|---|---|---|
| 1 | 1 | 11 | 6 |
| 2 | 2 | 12 | 7 |
| 3 | 3 | 13 | 8 |
| 4 | 4 | 14 | 9 |
| 10 | 5 | 20 | 10 |
In the decimal system we use ten digits; in the quinary system only five. We count in quinary as 0, 1, 2, 3, 4, 10, 11, 12, 13, 14, 20, … , 44, 100, 101, …
Which of these can be a quinary number?
Pick an answer to see why.
2.2.2 The quinary number system and its expansion
Expand 179 in the same way, as powers of 5:
So 179 = 1204₅. Each place is 5 times the place on its right.
As the decimal system’s places are one, ten, hundred, thousand, …, the quinary system’s are one, five, twenty-five, one hundred twenty-five, … (). A quinary number is written with the suffix 5.
2.2.3 Conversion from the decimal number system to quinary
The ladder works just as it did for binary, with 5 in place of 2: each division packs bundles into fives, and the remainder, now 0 to 4, is what doesn’t pack.
To change a decimal number to quinary, keep dividing by 5 until the quotient is 0, writing each remainder at the right of its step. Then write the remainders from bottom to top.
2.2.4 Conversion from the quinary number system
Expand 142013₅ in powers of 5:
So 142013₅ = 5883. To change a quinary number to decimal, write it in expanded form in powers of 5, then simplify. Unlike binary, here each digit must be multiplied: a 4 in the 625 place is worth 2500.
To change a number from quinary to binary, or from binary to quinary, go through decimal: the decimal number is the bridge between them.
What is 30₅ in decimal?
Pick an answer to see why.
Where this is used
Binary is everywhere. Every number, photo, song and message in a computer or a phone is stored in it. A QR code is binary you can see: its small squares are dark or light, and a phone camera reads them as data. Grade 9’s computer books go on to two more bases, 8 and 16, that programmers use as a short way of writing long binary numbers.
Quinary is rarely used. Computers don’t work in it. We learn it for a better reason: once you can work in a second and a third base, you can see what place value really is, and that 10 is a choice, not a law of nature.
How the exam asks it
Grade 8’s final exam follows CDC’s specification grid for Mathematics, Grades 6–8. There, Arithmetic is 14 marks in three questions, and each question is built around a real setting with parts at different levels. The grid’s Grade 8 model paper uses this unit in question 4, about a village water tank:
| Part | Level | Marks | What it asks |
|---|---|---|---|
| d. | higher ability | 1 | a shaded box means 1 and an empty box means 0; shade six boxes to show 43 in binary |
That is Example 1 of this unit, with boxes for an answer: 43 = 101011₂, so the boxes run shaded, empty, shaded, empty, shaded, shaded. Work the ladder on your rough paper, and check it before you shade. Here is one of our own in that shape.
Exercise 2.1
Question 1
Write each number in expanded form, using powers of 10.
Write 546 in expanded form.
Answer
Write 6542 in expanded form.
Answer
Write 1234 in expanded form.
Answer
Write 45872 in expanded form.
Answer
Write 258963 in expanded form.
Answer
Write 97332 in expanded form.
Answer
Question 2
Express each number as a sum of powers of 2, and as a sum of powers of 5.
Express 10 as a sum of powers of 2 and as a sum of powers of 5.
Answer
Express 25 as a sum of powers of 2 and as a sum of powers of 5.
Answer
Express 59 as a sum of powers of 2 and as a sum of powers of 5.
Answer
Express 402 as a sum of powers of 2 and as a sum of powers of 5.
Answer
Express 805 as a sum of powers of 2 and as a sum of powers of 5.
Answer
Express 932 as a sum of powers of 2 and as a sum of powers of 5.
Answer
Question 3
State the number system of each number.
Which number system is 10011₂ in?
Answer
Which number system is 350 in?
Answer
Which number system is 1001₂ in?
Answer
Which number system is 42₅ in?
Answer
Which number system is 555 in?
Answer
Which number system is 77532 in?
Answer
Which number system is 10010011₂ in?
Answer
Which number system is 257903 in?
Answer
Which number system is 4023₅ in?
Answer
Which number system is 5321 in?
Answer
Which number system is 1234₅ in?
Answer
Which number system is 101011₂ in?
Answer
Question 4
Change each decimal number to binary.
Change 4 to binary.
Answer
Change 9 to binary.
Answer
Change 12 to binary.
Answer
Change 25 to binary.
Answer
Change 35 to binary.
Answer
Change 79 to binary.
Answer
Change 94 to binary.
Answer
Change 100 to binary.
Answer
Change 104 to binary.
Answer
Change 135 to binary.
Answer
Change 190 to binary.
Answer
Change 220 to binary.
The textbook prints 22 here, but its answer key gives 11011100₂, which is 220, so the printed 22 doesn’t fit its own answer. We use 220, and the answer gives 22 as well.
Answer
Change 250 to binary.
Answer
Change 275 to binary.
Answer
Change 366 to binary.
Answer
Change 512 to binary.
Answer
Change 530 to binary.
Answer
Change 600 to binary.
Answer
Question 5
Change each binary number to decimal.
Change 11₂ to decimal.
Answer
Change 101₂ to decimal.
Answer
Change 111₂ to decimal.
Answer
Change 1100₂ to decimal.
Answer
Change 10101₂ to decimal.
Answer
Change 11001₂ to decimal.
Answer
Change 10010₂ to decimal.
Answer
Change 11110₂ to decimal.
Answer
Change 100001₂ to decimal.
Answer
Change 111111₂ to decimal.
Answer
Change 1100011₂ to decimal.
Answer
Change 1110011₂ to decimal.
Answer
Change 1100110011₂ to decimal.
Answer
Change 1010101110₂ to decimal.
Answer
Change 100001000₂ to decimal.
Answer
Change 101110111₂ to decimal.
Answer
Change 11011011001₂ to decimal.
Answer
Change 1111111110₂ to decimal.
Answer
Question 6
Change each decimal number to quinary.
Change 9 to quinary.
Answer
Change 13 to quinary.
Answer
Change 21 to quinary.
Answer
Change 26 to quinary.
Answer
Change 45 to quinary.
Answer
Change 55 to quinary.
Answer
Change 86 to quinary.
Answer
Change 112 to quinary.
Answer
Change 194 to quinary.
Answer
Change 404 to quinary.
Answer
Change 497 to quinary.
Answer
Change 650 to quinary.
Answer
Change 1128 to quinary.
Answer
Change 1234 to quinary.
Answer
Change 2125 to quinary.
Answer
Change 2536 to quinary.
Answer
Change 3000 to quinary.
Answer
Change 3650 to quinary.
Answer
Question 7
Change each quinary number to decimal.
Change 21₅ to decimal.
Answer
Change 24₅ to decimal.
Answer
Change 34₅ to decimal.
Answer
Change 101₅ to decimal.
Answer
Change 123₅ to decimal.
Answer
Change 300₅ to decimal.
Answer
Change 343₅ to decimal.
Answer
Change 441₅ to decimal.
Answer
Change 2023₅ to decimal.
Answer
Change 1234₅ to decimal.
Answer
Change 2113₅ to decimal.
Answer
Change 3313₅ to decimal.
Answer
Change 2014₅ to decimal.
Answer
Change 4201₅ to decimal.
Answer
Change 4321₅ to decimal.
Answer
Change 12304₅ to decimal.
Answer
Change 10123₅ to decimal.
Answer
Change 21432₅ to decimal.
Answer
Question 8
Change each number to binary if it is quinary, and to quinary if it is binary.
Change 40₅ to binary.
Answer
Change 10101₂ to quinary.
Answer
Change 31₅ to binary.
Answer
Change 101₂ to quinary.
Answer
Change 144₅ to binary.
Answer
Change 101110₂ to quinary.
Answer
Change 23₅ to binary.
Answer
Change 111₅ to binary.
Answer
Change 10011₂ to quinary.
Answer
Change 110111₂ to quinary.
Answer
Change 313₅ to binary.
Answer
Question 9
Compare each pair and find the difference, as a decimal number.
Which of 1101₂ and 24₅ is larger? Find their difference.
Answer
Which of 110011₂ and 144₅ is larger? Find their difference.
Answer
Printable PDFs
- Study notes 2 pages
- Harder practice questions 2 pages Answer key
Practice every question in the book, and keep track of the ones you miss →
Where these facts come from
- The exam (For the exam, How the exam asks it): CDC, विशिष्टीकरण तालिका (कक्षा ६-८) गणित – नमुना प्रश्नहरु (Arithmetic 14 marks in three questions; Grade 8 model question 4d, 1 mark, higher ability); our question is our own.
- Hindu-Arabic numerals: Wikipedia, “Arabic numerals” (Fibonacci’s 13th-century Liber Abaci and the numerals’ spread in Europe), read November 2026; al-Khwarizmi as in Where Did Our Zero Come From?.
- Pingala, Leibniz and Shannon (the story): Wikipedia, “Binary number” (Pingala, about the 2nd century BC, a unique value for each meter; Leibniz’s Explication de l’Arithmétique Binaire, 1703; Shannon’s master’s thesis, 1937, which “essentially founded practical digital circuit design”), read November 2026.
- Memory sizes (fact in 2.1.2): Wikipedia, “Binary prefix” (binary addressing made main memory sizes powers of two), read November 2026.
- Fives (fact in 2.2.1): Wikipedia, “Quinary” (Gumatj, reported as a 5–25 language; Roman numerals as biquinary), “Tally marks” (grouped in fives) and “Bi-quinary coded decimal” (the abacus), read November 2026.
- QR codes (Where this is used): Wikipedia, “QR code”, read November 2026.
- Every answer: worked out here and checked by a computer program against the place values.
A companion to your textbook, not a replacement for it: study from the book your school uses, and where the two differ, follow your teacher. Found a mistake? Please tell us.
