Turning Letters and Colors into Numbers
Byte the robot sits at a giant mechanical decoder wheel inside a colorful code factory, spinning dials to match letters to numbers while rainbow paint cans labeled with number codes line the shelves behind them.
- Explain that computers store all information as numbers.
- Identify the number code for at least one letter using a simple chart.
- Compare how letters and colors are both turned into numbers for a computer.
- Predict what a computer would store when you type the letter A.
Key terms
- Number code
- A number that stands for a letter or color.
- ASCII
- A code giving each letter its own number.
- RGB
- Three numbers for red, green, and blue.
- Data
- Information a computer stores as numbers.
Letters Become Numbers
Computers cannot read letters the way you do. So every letter gets its own number using a code called ASCII. The letter A is 65, B is 66, and C is 67. When you type a word, the computer quietly turns each letter into its number and stores those numbers instead.
Colors Become Numbers Too
Every color on your screen is stored as three numbers. One number says how much red, one says how much green, and one says how much blue. Pure red is 255, 0, 0. Pure blue is 0, 0, 255. The computer mixes these amounts to make every color you see on the screen.
Numbers Are the Only Language
The computer never keeps the letter A or the color red the way you picture them. It always keeps a number instead. Numbers are the only thing a computer truly understands, so people made clever codes to turn letters, colors, and symbols into numbers the computer can store.
Worked examples
What numbers store the word CAB?
- C is 67, using the ASCII code.
- A is 65 and B is 66.
- Put them in order: 67, 65, 66.
Answer: The computer stores 67, 65, 66.
What three numbers make pure green?
- Green needs no red, so red is 0.
- Green is full, so green is 255, and blue is 0.
Answer: Pure green is 0, 255, 0.
Activity
Match each letter or color to its correct number code on the decoder board.
Practice
Write the ASCII number for the letter A on its own.
Name the three colors a computer mixes to make any color.
Common mistakes to avoid
- Computers store the letter shapeComputers store a number code, not the drawn shape of a letter.
- Computers remember color namesComputers store three numbers for red, green, and blue amounts.
Check your understanding
When you type the letter B on a keyboard, what does the computer actually store?
A friend says computers store colors by remembering the name of the color, like the word 'red.' Is your friend correct?
Which of these best describes why computers use number codes for letters and colors?
Recap
Computers only understand numbers. Letters get number codes through ASCII, so A is 65. Colors get three numbers for red, green, and blue. The computer always stores numbers, never the real letter or color you see.
Reflect
What letter would you most like to find the number for?