Computers store and process everything, numbers, text, images, and sound, as patterns of two states, usually written as 0 and 1. A single such digit is a bit, and eight bits form a byte. To understand how computers represent information we need to be fluent in the binary number system and in a convenient shorthand for it, hexadecimal.
The everyday denary (base-10) system uses digits 0–9 and place values that are powers of ten. Binary (base-2) uses only the digits 0 and 1, and its place values are powers of two: $1, 2, 4, 8, 16, 32, \dots$ Reading a binary number means adding the place values wherever a 1 appears. For example:
$$1011_2 = 8 + 0 + 2 + 1 = 11_{10}$$
To convert denary to binary, repeatedly subtract the largest power of two that fits, or divide by