Sei sulla pagina 1di 4

Computer Science: BINARY 1

Binary is a way of representing numbers and letters using only 1’s and 0’s.
Here is an example:
128 64 32 16 8 4 2 1
The number 12 in binary is:
0 0 0 0 1 1 0 0
As you have no 64s, no 32’s, no 16’s, one 8, one 4, no 2’s and no 1’s
Each one and zero could represent a light bulb being turned on or off.
 For example here is the light combination for 12: So 8+4 = 12

64 32 16 8 4 2 1

This is how the first computers worked. By having lights (Valves) which were turned on and off to give
different binary patterns

Task 1 - Turn on the lights for the following:

1. 1001010
64 32 16 8 4 2 1

2. 0101011
64 32 16 8 4 2 1

3. 40 = 0101000

64 32 16 8 4 2 1

4. 17

64 32 16 8 4 2 1

Name: Budmouth College (ZG) 1


Computer Science: BINARY 1

5. 73

64 32 16 8 4 2 1

6. 65

64 32 16 8 4 2 1

7. 102

64 32 16 8 4 2 1

Binary patterns can also be used to represent characters. The standard way of doing
this is using ASCII where each letter is given a number. This is part of the ASCII table :
065 --A--
066 --B-- 067 --C-- 068 –D-- 069 --E-- 070 --F-- 071 --G--
072 --H-- 073 --I-- 074 --J-- 075 --K-- 076 --L-- 077 --M--
078 --N-- 079 --O-- 080 --P-- 081 --Q-- 082 --R-- 083 --S--
084 --T-- 085 --U-- 086 –V-- 087 --W-- 088 --X-- 089 --Y--
090 --Z--

So for example A = 65
65 in binary is: 128 64 32 16 8 4 2 1

As you have one 64 and one 1: 0 1 0 0 0 0 0 1


64+1 = 65
So in light bulbs you’d have:

64 32 16 8 4 2 1

Name: Budmouth College (ZG) 2


Computer Science: BINARY 1

Task 2 - Using the ASCII table above turn on the lights for each letter:
1. D

64 32 16 8 4 2 1

2. M

64 32 16 8 4 2 1

3. Q

64 32 16 8 4 2 1

You can also represent small letters using ASCII here is the table for them:
097 --a-- 098 --b-- 099 --c-- 100 --d-- 101 --e--
102 --f-- 103 --g-- 104 --h-- 105 --i-- 106 --j-- 107 --k--
108 --l-- 109 --m-- 110 --n-- 111 --o-- 112 --p-- 113 --q--
114 --r-- 115 --s-- 116 --t-- 117 --u-- 118 --v-- 119 --w--
120 --x-- 121 --y-- 122 --z-

4. f

64 32 16 8 4 2 1

5. u

64 32 16 8 4 2 1

Name: Budmouth College (ZG) 3


Computer Science: BINARY 1

6. x

64 32 16 8 4 2 1

Task 3

Using Copy and Paste (and Group and Ungroup) spell out your first name using lights.

For example if your name was Bob:

B: 66 = 1000010
o: 111 = 1101111
b: 98 = 1100010

64 32 16 8 4 2 1

64 32 16 8 4 2 1

64 32 16 8 4 2 1

Name: Budmouth College (ZG) 4

Potrebbero piacerti anche