Bits and Binary
Computers store everything as 0s and 1s. Learn bits and bytes, count in binary with a binary machine, and see how letters become numbers.
Welcome back!
Step 1 of 12Learn
Billions of tiny switches
Inside a processor are billions of super tiny switches called transistors. A switch can only be off or on, like a light switch.
Computers use 0 for off and 1 for on. Each single 0 or 1 is called a bit. A group of 8 bits is called a byte.
One switch cannot say much. But with lots of them, a computer can store any number, letter, color or sound. Everything you see on a screen is really a huge pile of 0s and 1s.
Step 2 of 12Practice · Fill in the blanks
Fill in the blanks
A single 0 or 1 is called a . A group of 8 of them is a .
Step 3 of 12Flashcards
Computer code words
Tap a card to flip it.
Step 4 of 12Learn
Counting with two digits
You count with ten digits, 0 to 9. Computers count with only two: 0 and 1. This is called binary.
In binary, each place is worth double the place to its right: 8, 4, 2, 1. To read a binary number, add up the places that have a 1.
Example: 0101 has a 1 in the 4 place and the 1 place. 4 + 1 = 5.
Another: 1100 has 1s in the 8 and 4 places. 8 + 4 = 12.
Step 5 of 12Tap to reveal
Read 1011 step by step
8 place
It has a 1, so count 8.
4 place
It has a 0, so count nothing.
2 place
It has a 1, so count 2.
1 place
It has a 1, so count 1.
Add them
8 + 2 + 1 = 11. So 1011 in binary is 11.
Step 6 of 12Try the calculator
Binary machine
Set each switch to 0 (off) or 1 (on) and watch the number change. Can you make 10? Can you make 15?
- Number
- 5
Step 7 of 12Practice · Work it out
What number is 0011 in binary?
Step 8 of 12Practice · Work it out
What number is 1010 in binary?
Step 9 of 12Practice · Choose one
With four switches (8, 4, 2, 1), what is the biggest number you can make?
Step 10 of 12Learn
Letters are numbers too
How does a computer store the letter A? It gives every letter a number! In a common code, A is 65, B is 66 and C is 67. Small letters have their own numbers: a is 97.
That number is stored in binary inside one byte. Pictures work the same way. A picture is made of tiny dots called pixels, and each pixel's color is saved as numbers.
Step 11 of 12Compare
Letters as numbers
| Aspect | Number | Binary (1 byte) |
|---|---|---|
| A | 65 | 01000001 |
| B | 66 | 01000010 |
| C | 67 | 01000011 |
| a | 97 | 01100001 |
Step 12 of 12Practice · True or false
Inside the computer, the letter A is stored as a number made of 0s and 1s.
Lesson complete!