☰ خطة العام · تكنولوجيا المعلومات والاتصالات (بالإنجليزية)

Binary numbers: the language of computers

الأسبوع 24 · المحور الرابع، الدرس ٣ «مقدمة إلى الأعداد الثنائية»: النظامان العشري والثنائي · 3 دروس
1

Two states: on and off

ICT P5 Term 2, Theme 4: pp. 54–57
GoalExplain why computers use two states, on and off, written as 1 and 0.
New words
binary · using only two digits, 0 and 1state · the condition something is in, such as on or offswitch · a part that turns electricity on or offdigit · one of the symbols used to write numbers, such as 0, 1 or 7
Explanation

A light switch has only two states: on or off. Computers work in the same way. Inside them are tiny switches. Each one is either on, which we write as 1, or off, which we write as 0. Everything a computer stores or sends, such as numbers, words, pictures and music, is changed into lines of 1s and 0s. This is called the binary number system. Why only two? Because the simplest and most reliable design for wires and circuits has just two states. It is much easier to tell ‘on’ from ‘off’ than to tell ten different levels of electricity. With enough switches in a row, you can make many different patterns, just as a few letters can make many words.

StateLight switchComputer
onlight is on1
offlight is off0
Worked examples
1 switch: 22 switches: 43 switches: 8
With one switch there are 2 patterns: off (0) and on (1). With two switches there are 4 patterns: 00, 01, 10, 11. Each new switch doubles the number of patterns.
tiny switchesmany patterns
Three switches make 2 × 2 × 2 = 8 patterns: 000, 001, 010, 011, 100, 101, 110, 111. A computer with millions of tiny switches can make a very large number of patterns.
101
Mariam says: ‘My torch has two states, so it is like a computer switch. I can code a message: one flash for 1, no flash for 0.’ Her friend sees 1-0-1 and writes it down.
Class activity

Coin patterns. Take three coins and let heads be 1 and tails be 0. Toss them and write the pattern, for example 1 0 1. Do it until you have found all 8 different patterns. Check that you have 000, 001, 010, 011, 100, 101, 110 and 111. If you have no coins, cut three small pieces of paper, colour one side, and use coloured side = 1. Then explain to a partner why a computer likes two states.

Practice
1
What are the two states of a computer’s tiny switches?
2
How many patterns can two switches make?
3
How many patterns can three switches make?
4
Why do computers use only two states?