Menu

Binary and Hexadecimal Basics

Why Computers Use Binary

Computers use binary because of the way their hardware is built. Inside a computer are huge numbers of tiny switches called transistors, and each one can only be in one of two states: on or off. Those two states are written as 1 for on and 0 for off. Binary is therefore a natural fit for the electronics rather than a style choice made by programmers.

Two states are quick and reliable

A transistor is switched by a voltage. A high voltage means on (1) and a low voltage means off (0). It is easy for a circuit to tell these two apart, even if the voltage drifts a little, so mistakes are rare.

Imagine a torch with one switch: pressed is on, released is off. Now picture a row of eight such switches side by side. Each switch adds one more bit, so the row as a whole can hold a pattern such as 0 1 1 0 1 0 0 1. A machine could be built with ten voltage levels instead of two, but neighbouring levels would be close together and easily misread, so sticking to two states is far safer.

Everything becomes a pattern of bits

Every item of data and every instruction is held and worked on as a sequence of 1s and 0s. A single binary digit is called a bit, and it is always either 0 or 1. A photograph, a song, a paragraph of writing and an instruction such as add two numbers all end up as different arrangements of bits. The computer never sees the picture or the words themselves: it only ever flips switches on and off in a chosen order, and the meaning comes from how that pattern of 1s and 0s is interpreted.

Practise this

OCR GCSE Computer Science · Binary and Hexadecimal Basics

OCR GCSE Computer Science · Units and File Sizes