AdvertisementYour brand could be hereYour brand hereOn every Darslab page · students, parents and teachersinfo@darslab.comAsk for pricesPricesinfo@darslab.com
☰ Year plan · Computing

Year round-up

Week 30 · Review: Term 3 · 3 lessons
1

Networks and keeping safe

Computing 8: Topics 3.1–4.5, pp. 230–299
GoalName a network type from three questions, choose a connection with reasons, and explain how an echo check and a firewall protect data.
New words
PAN, LAN, WAN · networks of growing size: close to one person, in one building or site, and over a wide areafibre optic · a cable that carries data as light through very thin glassecho check · a way of finding errors in which the receiver sends a copy back and the sender compares it with the originalfirewall · software or hardware that checks incoming and outgoing data against rules and blocks what is not allowed
Explanation

To name a network, ask three questions: how many devices, where are they, and who owns the hardware? A PAN is small and close to one person, a LAN covers one building or site, and a WAN covers a wide area and often uses lines owned by an ISP. Copper cables send electrical signals and can suffer from interference. Fibre optic cables send light through glass, so they are faster and better for long distances. Wireless links need no cable, so devices can move, but walls and distance weaken the signal. During transmission interference can change a bit, so an echo check sends the data back and compares the copy with the original. A firewall checks data against its rules. Antivirus software scans files and can put a dangerous one in quarantine.

laptopfirewallcomputer
Worked examples
SituationDevicesWhereWho owns the hardwareNetwork
a Bluetooth speaker and a phone, both Yuki’s2within arm’s reachone personPAN
12 computers and 2 printers in a youth club building, joined by cables14one buildingthe clubLAN
a charity’s offices in Cairo and Nairobi, joined by lines rented from an ISPmanydifferent countriesthe charity owns its computers, the ISP owns the long linesWAN
Naming three networks with the three questions. The first two stay close to their owners. The third crosses countries and uses long lines that the ISP owns.
Python
1metres = int(input("Length of the link in metres? "))
2if metres > 100:
3    print("Use fibre optic")
4else:
5    print("Use copper cable")
Output
Use fibre optic
Choosing a cable by distance. A club’s rule says that links longer than 100 metres use fibre optic, because light in glass keeps a strong signal over long distances and suffers no electrical interference. Shorter links use copper, which is cheaper and easier to fit. With 450 typed, 450 > 100 is true, so the output is Use fibre optic. With 30 typed it would be Use copper cable.
Bit position12345678
Sent01101001
Copy01101101
Same?yesyesyesyesyesNOyesyes
An echo check. The sender sends 01101001. Interference changes one bit on the way, and the receiver sends back 01101101. The sender compares the two codes bit by bit and finds that bit 6 is different, so it sends the data again.
Class activity

Network detectives (no computer). Draw a card for each of five places, such as a bus stop display, a football club, a family’s flat, a bank with branches in two countries and a remote control with a television. Decide the network type for each and tick the three questions: devices, where, owner. Then play the echo game: one player writes an 8-bit code, says it aloud to a partner, who writes what they heard and reads it back. The first player compares the two codes and says which bit differs or Match. Finally write a house rule for the family: three safe habits for passwords and for opening files from people you do not know. If you have a computer or tablet, an adult can show you where a firewall setting is.

Practice
1
Name the network and give one reason: (a) a smart speaker and a phone in Omar’s bedroom, both his; (b) 200 shops of a company in 12 countries sharing one stock system; (c) 30 computers in a call centre building, owned by the company.
2
What does the program print for (a) yes and 20, (b) no and 300, (c) no and 15, (d) Yes and 20? Explain answer (d).
Python
1moving = input("Does the device move around? ")
2metres = int(input("Distance in metres? "))
3if moving == "yes":
4    print("Wireless")
5elif metres > 100:
6    print("Fibre optic")
7else:
8    print("Copper cable")
3
A firewall rule lets in only two addresses. Predict what the program prints for 198.51.100.8, for 198.51.100.48 and for an empty answer.
Python
1address = input("Address? ")
2if address == "198.51.100.4" or address == "198.51.100.8":
3    print("Allowed")
4else:
5    print("Blocked")
4
The sender sent 10110011 and got back 10100011. Which bit is different, and what should the sender do? Does a matching copy prove that nothing could have gone wrong? Explain briefly.