Year 8 Computing: Summer Assessment
The whole of Year 8, with most of the marks on Python, spreadsheets, networks and cyber security, and web development.
Exam timer
Sit this to the clock. Working under time pressure is a separate skill from knowing the content, and it is the one most students never practise.
Instructions
- Answer every question.
- The marks tell you how many creditworthy points are wanted.
- No calculator is permitted.
- Where a question says write a formula or write code, write it exactly as you would type it. Where a question asks you to compare, you must write about both things, not just one of them.
Questions
Write a full answer to every question, then mark the whole paper at the end. Marking as you go teaches you far less.
- LSwitch
A switch. It connects the devices within a single network and, unlike a hub, it sends each piece of data only to the device it is addressed to.
- LA for loop repeats a known number of times, a while loop repeats while a condition is true
- LGives a situation where the number of repeats is not known in advance
A for loop repeats a known number of times, such as exactly ten times or once for every item in a list, while a while loop keeps repeating for as long as its condition stays true. A while loop is the better choice when you do not know in advance how many repeats are needed, for example when asking the user for a password and continuing to ask until they type the right one.
- L=AVERAGE(B2:B31)
- L=MAX(B2:B31)
The average is =AVERAGE(B2:B31) and the highest mark is =MAX(B2:B31). Both must start with an equals sign, otherwise the spreadsheet treats what has been typed as ordinary text, and both use a range written as the first cell, a colon, then the last cell.
- LThe data is broken into small pieces that travel separately
- LOne large file cannot block the network for everybody else
- LIf a packet is lost only that packet is resent, and packets can take different routes
Data is split into packets because sending one enormous file as a single lump would tie up the connection completely and everybody else would have to wait until it had finished. Small packets from different users can be interleaved, so everyone gets a share of the line. Splitting the data also makes the transfer far more reliable, because packets can take different routes to the destination and if one is lost or damaged only that single packet has to be sent again rather than the whole file. Each packet carries the destination address, the sender's address and a packet number so that the receiving computer can put them back in the right order.
- LThe browser asks a DNS server for the IP address that matches the name
- LA request is sent to the web server at that IP address
- LThe server sends the page back in packets, which are reassembled and displayed
The browser first asks a DNS server to look up the IP address that matches the name that has been typed, because computers route data by number rather than by name. The DNS server replies with an address such as 93.184.216.34. The browser then sends a request to the web server at that address. The server responds with the page, which is broken into packets that may travel by different routes and arrive out of order. The user's computer reassembles them in the correct order using the packet numbers, and the browser then renders the HTML and CSS into the page you see.
- LA relative reference changes when the formula is copied
- LAn absolute reference uses dollar signs and stays the same when copied
- LNeeded when every row must use the same cell, such as a rate stored once
A relative reference such as B2 changes when the formula is copied, so copying it down one row makes it B3 and copying it right one column makes it C2. That is usually what you want, because a column of totals should refer to a different row each time. An absolute reference such as $B$2 has dollar signs that lock it, so it stays exactly the same wherever the formula is copied. An absolute reference is needed when every row has to refer to the same single cell, for example a VAT rate or a price per ticket stored once at the top of the sheet. Without the dollar signs the reference would slide down the sheet and the later rows would multiply by empty cells.
- LA screen reader reads the alt text aloud to the user
- LIt is displayed if the image fails to load
- LWithout it those users lose the information the image carries
Alt text is the description written into the alt attribute of an image tag. Software that reads a page aloud, used by people who are blind or have very limited vision, reads the alt text in place of the picture, so it is the only way those users receive whatever the image is communicating. It also appears on the screen when the image itself fails to load, for example on a very slow connection. Without alt text the image is simply a gap, and any information it carried is lost, which is why alt text is treated as part of building an accessible site rather than as an optional extra.
- LNothing inside the loop changes the value being tested
- LThe condition therefore stays true and the loop never ends
- LFix it by changing that variable inside the loop, for example count = count + 1
A while loop keeps running for as long as its condition is true, and the condition is only rechecked at the top of each pass. If nothing inside the loop changes the variable that the condition tests, that condition can never become false, so the loop runs forever and the same value is printed over and over. The fix is to make sure something inside the loop changes the value being tested, such as adding the line count = count + 1 inside the loop so that count eventually reaches the limit and the loop stops.
- LCreates a list and uses a loop that repeats five times
- LConverts each input to a number and appends it to the list
- LUses max to find the largest value
- LUses sum divided by len for the average and prints both results
numbers = [] to start with an empty list. Then for i in range(5): numbers.append(int(input('Enter a number: '))). The int is needed because input hands back text. Then print('The largest is', max(numbers)) and print('The average is', sum(numbers) / len(numbers)). Using len rather than typing 5 means the program still works if the number of values is changed later.
- LCorrect h1 element containing the words Bike Club
- LParagraph opened and closed with p tags
- LAn img element with a src attribute naming the file
- LAn alt attribute that actually describes the picture
The HTML is <h1>Bike Club</h1>, then <p>We meet every Thursday after school and ride together for an hour.</p>, then <img src='bike.jpg' alt='A blue mountain bike leaning against a gate'>. The h1 element marks the most important heading on the page, the p element wraps the paragraph and must be closed, and the img element is self closing and needs a src attribute giving the file name plus an alt attribute describing what the picture shows.
- LKeep regular backups of important data, stored separately
- LFiles can then be restored without paying the criminals
- LUse anti malware software and install software updates
- LThese detect and remove known threats and close the weaknesses malware uses
The first measure is to keep regular backups of everything important, held separately from the main network so that the ransomware cannot encrypt them as well. If an attack succeeds, the school can wipe the affected machines and restore the files from the backup, which removes the entire point of the attack because there is no reason to pay for a key to data you already have. The second measure is to run anti malware software and to install operating system and application updates promptly. Anti malware scans files against known threats and removes them before they run, and updates close the security weaknesses that ransomware relies on to get in, since most successful attacks use flaws that were fixed months earlier.
- LCode written once can be called many times
- LThe program is shorter and there is less repeated code
- LA fault only has to be corrected in one place
- LEach function can be tested on its own and the program is easier to read
The first reason is reuse. A calculation that is needed in six different places is written once as a function and then called six times, which makes the program considerably shorter and removes the repeated code. That also means a mistake in that calculation only has to be corrected in one place rather than hunted down in six, which is where most bugs in long programs come from. The second reason is that the program becomes far easier to read and to test. Each function has one clear job and a name that says what it does, so the main part of the program reads almost like English, and each function can be tested on its own before it is trusted in the finished program.
- LWired connections are faster and more consistent
- LWired connections are more reliable, as the signal is not weakened by distance or walls
- LWired connections are more secure, since physical access is needed
- LWireless is cheaper and quicker to install and lets devices move around
- LGives a clear recommendation and justifies it for this situation
A wired connection is faster and far more consistent, because the data travels along a cable that nothing else is sharing, and it is more reliable since the signal is not weakened by distance, walls or interference from other equipment. It is also more secure, because an attacker would have to get into the room and physically plug in rather than simply being close enough to pick up a signal travelling through the air. Wireless has real advantages too. It is much cheaper and quicker to install because no cables have to be run through walls and floors, and it lets tablets and laptops be moved around the room or taken to another part of the school. For a room of fixed desktop computers that never move, the school should use wired connections, because speed, reliability and security matter more than mobility and the machines are staying where they are. A wireless access point should be added as well, so that visiting laptops and tablets can still connect.
This is an original paper written to match the structure, question style, command words and mark allocation of the real MskProd Year 8 Summer assessment. It is not a past paper. Real past papers are the copyright of the exam board and cannot be republished here, so links to the official papers on the board's own site are provided on the exam papers page.