5
Binary Numbers and Codes
A binary code is any system that only uses 2 states: 1/0, on/off, true/false etc.
A binary number is any number containing only 1’s and 0’s. These are all examples of binary
numbers:
101
000000
1111111
10001001010010
10001111101010
0101010101010
Binary numbers have all sorts of applications, many of which are used on a daily basis, like:
• Computers
• Barcodes
• Calculators
• CD’s and DVD’s
• TV’s
• Braille
Binary codes are also used in many work fields, such as computer science, software engineer-
ing and electrical engineering - and basically all other fields of engineering too!
There are multiple ways to express a binary code, the two most common forms of writing a
binary code using numbers are ‘Decimal form’ and ‘Binary form’.
For example: 1101 in binary form becomes 13 in decimal form. And 1001 becomes 9.
Now, the conversion between these may not be obvious, but it’s pretty easy. Before we jump
into converting between binary and decimal forms, let’s do a quick review on exponents:
0
= 1
1
=
2
=
3
=
4
=
5
=
and so on... (for any )
Also, fill out this table, it will be very useful for the rest of the lesson.
0
1
2
3
4
5
6
7
8
0
1
2
3
4
5
6
7
8
2
2
=
1
2
=
2
2
=
4
2
=
8
2
=
16
2
=
32
2
=
64
2
=
128
2
=
256
5