Binary

Binary and Decimal

Decimal means numbers are written in base 10 using the digits 0 to 9

Binary means numbers are writtenmin base 2 using the digits 0 and 1

Computer systems use binary numbers to encode all information because

  1. Electronically it is easier to represent just two values
  2. It is easier to build electronic circuitry for carrying out calculations when only two values are involved
  3. The significant advances in hardware mean that it is possible to store and process enormous quantities of digital information (information that is held in codes made up of 1s and 0s)

Converting Decimal to Binary

 

What is 73 in binary?

The column headings are always (right to left)  1, 2, 4, 8, 16, 32, 128 and so on. These are powers of 2.

128

64

32

16

8

4

2

1

0

1

0

0

1

0

0

1

  1. Does 128 go into 73? – The answer is no, so we put a 0
  2. Does 64 do into 73? – The answer is yes, so we put a 1 – with a remainder of – (73-64 = 9)
  3. Does 32 go into 9? – The answer is no, so we put a 0
  4. Does 16 go into 9? – The answer is no, so we put a 0
  5. Does 8 go into 9? – The answer is yes, so we put a 1 – with a remainder of – (9-8 = 1)
  6. Does 4 go into 1? – The answer is no, so we put a 0
  7. Does 2 go into 1? – The answer is no, so we put a 0
  8. Does 1 go into 1? – The answer is yes, so we put a 1

Put 1s and 0s in the right columns so that the numbers add up to 73

64 + 8 + 1 =73

Answer: 73 in decimal = 01001001 in binary

Converting  Binary to Decimal

What is 11001110 in binary?

The column headings are always (right to left)  1, 2, 4, 8, 16, 32, 128 and so on. These are powers of 2.

128

64

32

16

8

4

2

1

1

1

0

0

1

1

1

0

Put 1s and 0s in the correct columns headings as shown above.

128 + 64 +  8 + 4 + 2 = 206

Answer: 11001110 in binary = 206 in decimal