MyLeoNes™

Binary representation — Technology, 14–17 years

Computers represent information with patterns of two states, written as 0 and 1. The same idea can describe numbers, text, images and sound.

Two states can carry information

Binary uses only two symbols, usually 0 and 1. Each position has a value that doubles as you move left: 1, 2, 4, 8 and so on. A computer can store and process these states using physical differences such as electrical charge, light or magnetism.

Why only zero and one?

Electronic components are good at distinguishing two reliable conditions, such as a signal being present or absent. Using two states makes circuits easier to build and less vulnerable to small disturbances than many delicate levels would be. Binary is therefore not a claim that the world has only two possibilities; it is a practical language for machines.

Turning 13 into binary

Use the place values 8, 4, 2 and 1. The number 13 contains 8, leaving 5; it contains 4, leaving 1; it contains 1, leaving 0; it contains no 2. Write 1 under the values used and 0 under the value skipped: 8+4+0+1, so 13 is 1101 in binary.

Binary is not just a different font

It is tempting to read 1010 as the decimal number one thousand and ten, because the symbols look like ordinary digits. In binary, each position has powers of two, so 1010 means 8+0+2+0, which is 10. The symbols are familiar, but their place values have changed.

Files are patterns of bits

A photo, song or message becomes a long pattern of bits when a device stores it. Groups of bits are interpreted using agreed codes: one pattern may mean a letter, while many patterns may describe the colours of pixels. Compression can shorten the pattern, and errors in it may produce a distorted image or sound.

Keep exploring

Other languages

Loading MyLeoNes™…