Here's our Hardware Tip for.. June 4, 1999
Click Here to see a complete list of all of our previously released Tips!
The Hexadecimal Number System
A while back, we showed you how the Binary numbering system works.

Binary values are well suited for use in computer systems since it only uses two digits, 1s and 0s, with a 1 representing on and a 0 representing off.

Binary numbering however tends to create some very large numbers. Another numbering system called hexadecimal makes large binary numbers easier to manage.

It is common practice to convert large binary numbers to hexadecimal (hex), which is a numbering system based on powers of 16. The easiest way to convert binary numbers is to organize them in blocks of four bits, which easily converts to hex equivalents.

Here are the hexadecimal, binary, and decimal equivalents for the numbers 0 through 15.

Binary, Decimal, and Hexadecimal Equivalents
Binary Decimal Hexadecimal
0000 0 0
0001 1 1
0010 2 2
0011 3 3
0100 4 4
0101 5 5
0110 6 6
0111 7 7
1000 8 8
1001 9 9
1010 10 A
1011 11 B
1100 12 C
1101 13 D
1110 14 E
1111 15 F

Hexadecimal uses the letters A through F to represent digits ranging from 10 to 15 decimal. Hexadecimal numbers often are distinguished from decimal by an h that's added to the number. For example, 3135h is a hex number. You also might encounter the C programming convention of attaching Ox to the beginning of a number, such as Ox5A29.

To convert a binary number to hexadecimal, substitute the corresponding hexadecimal digit for each four-bit chunk:

Binary 0100 1010 0111 1110
Hex 4 A 7 E