You are on page 1of 58
DSU et ccaer Colla Moe) aa Rel eho) T3130 4 Sample answers have been written by the authors. In examinations the way marks are awardad may be diferent > Coursebook answers Chapter 1: Data representation The answer will depend on the students This will be an open-ended discussion Any three examples of data that is heard, smelt, seen or touched, eg. hearing music or a soundwave. It has lots of different possible values, rather than limited values like diserete data. 0 1 0 1 0 1 0 1 1 1 1 1 0 Bach bit in the byte is shifted either to the left or the right by a set number of places. The spaces left from the value shifted are replaced with 0 values, oo1n1o11 Tr could potentially remove data that is vital. All text in a file is likely to be required, so none can be removed. Yes, as it will remove some of the detail, such as reducing the number of colours used: to create the image. ‘Yes, as it will remove some of the natural background noises, ete. from the recording, 80 it won't be as close to the original, Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 1 continued Is oo 1001 oor 1010 onion 255 Lo100010 9p1 ‘Three times 1.500.000 Itis a continuous stream of data that is processed by humans. Iris discrete data that has two values, 1 and 0, and is processed by computer. Four from! A denary number system is a base 10 system, whereas a binary number system is a base 2 system. ‘The units in a denary number system increase by 10, whereas the units in a binary ‘number system increase by 2 A denary number system uses the values 0 (0 9, whereas a binary number system uses the values 0 and 1 A denary number system cannot be processed by a computer, whereas a binary ‘number system can be processed by a computer. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 1 continued One mark for two correct nibbles, two marks for three, for each conversion + 9010 0001 1010 + 1001 0000 1101 ove (One mark for one correct nibble, two marks full correct answer, one mark for demonstration of working, e.g. carried bits shown 1 0 0 1 ‘One mark for 10111000 One mark for correct working, one mark for correct answer. Convert 28 to binary number (00011100) Invert the values (11100011) Add | to get final answer (11100100) ‘Any one from: Compress the image: reduce the resolution; reduee the colour depth ‘Two marks for two stages of working, one mark for the correct answer. 150% 250=37 500 (number of pixels per image) 37 500% 16=600 000 (number of bits per image) 600 000/8=75 000 (number of bytes per image) 75.000/1024=73.24 (number of KiB per image) 73.24/1024=0.07 (number of MiB per image) 0.07#20= (number of MiB for 20 images)=1.43=1.4MiB NOTE: There can be several different ways of working and any two viable stages can be awarded. Any two from: + ess storage space required + ess time for webpage to load for readers + quicker to upload content to the blog. Four from: + Acompression algorithm is used + Patterns of notes in the file are identified + ..cand grouped with an index + No data is permanently removed from the file 1050MiB Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 2: Data transmission The answer will depend on the students, This will be an open-ended discussion, ‘They ate the packet header, the payload and the trailer/footer: It includes the destination address, the packet number and the originator’s address. The payload ‘The transmission media, such as the wires and radio waves, would not be able to transmit large amounts of data. It needs to be broken down into smaller units so that it can be sent using these, Parallel. It will allow the data to be transmitted quicker to the printer, to allow more leaflets to be processed per minute. It is also only a short distance, so parallel data transmission will still be reliable. Serial Parallel Serial half-duplex Any two from: ‘There is less chance of data being skewed or out of sequence, ast is sent one bit at atime ‘There i less chance of interference that could corrupt data, as only a single wire used. Tris cheaper to manufacture oF set up, as only a single wire used, It is more reliable over a longer distance. Any two from Trean only be used over a limited distance. There is more chance of interference as multiple wires are used. ‘There is more chance of errors in data as it is sent, multiple bits at a time and out of sequence. Tris more expensive to manufacture or set up, as multiple wires are used Serial full-duplex. The distance is too far to use a parallel cable. The customer data is valuable so it needs to be correct and serial transmission will have less chance of error, because a single wire is used, so less interference or skewing of data. Tt needs to be full-duplex as this is the only transmission method that will allow data to be sent in both directions at the same time, Universal serial bus Serial Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 2 continued Any two from: Tris@ universal standard, The cable can only be inserted one way into the port, so this helps prevent incorrect connections. i supports different transmission speeds. It is backward compatible, so USB2 cables can be inserted into USB3 ports Ttcan power another device whilst transmitting data Devices are automatically detected when connected The data transmission speed is relatively high. Five of, .g. keyboard, mouse, mobile phone, speaker, web camera, microphone. ‘5S metres, It is limited so that the data transmission rate can be kept fairly high. T would deteriorate over a greater distance. © (10101000) © (10001000) If an even number of bits had been transposed / interchanged, as it would still add up to an odd or even number, depending on the parity used. ‘The actual data / payload that is being transmitted, Itis attached / appended to the data that is being transmitted, so that it is transmitted with the data If the same calculation is performed on the data, it should get the same result, Ifthe results are different, the data must have changed during transmission, meaning that errors must hhave been introduced. No. It could be possible that the data arrived correctly, but that errors occurred in the data when it was being transmitted by back the sender. Encryption key Cipher text No, The data can still be stolen, as the hacker can still ake it, It will ust be meaningless to the hacker, as it will be scrambled ‘The same key is used in symmetric, and is transmitted with the data, so if a perpetrator steals the data, it is likely they will also have the key to decrypt it. Two different keys are used in asymmetric encryption and both are needed to decrypt the data. It makes it much more difficult for a perpetrator to obtain both keys to decrypt the data Any two from destination address packet number originator’s address. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 2 continued Any two from: + Bach data packet is sent individually, possibly along a different route, so it could arrive out of sequence, + The receiving device reads the packet number from the header and reorders, the packets based on this value. Any two from: + Bits of data are sent down a single wire + Bits of data are sent one at a time, + Data can be sent in both directions +... but only one direction at a time. Any two from Tris a universal standard, The cable can only be inserted one way into the port, so this helps prevent incorrect connections. Tt supports different transmission speeds. Tris backward compatible, so USB2 cables can be inserted into USB3 ports. Ti can power another device whilst transmitting data. Devices are automatically detected when connected. Data transmission speed is relatively high ‘Two from: + Serial + Pull duplex And four from: + The distance is too far to use a parallel cable + The data will have less chance of error +... because a single wire is used, so less interference or skewing of data. + Ineeds to be full duplex as this is the only transmission method that will allow data to be sent in both directions at the same time. ‘One mark for each correct row This mothod checks for orrors in data aftor it has been transmitted, This method can use an odd or even process. This method sends data back from the receiver to the sender to compare the data to check for errors. This method uses a value that is calculated from [7 tho data to check for errors. One mark for each correct term in the correct order: plain text; key: cipher text: meaningless; decrypted: the same. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 3: Hardware The answer will depend on the students, This will be an open-ended discussion, The answer will depend on the students. RAM Control unit To transmit data or signals in the fetch-execute cycle. Tt neods it to store interim results of calculations. If it did not have the accumulator, it would need to write and read the interim result to and from RAM each time. Program counter (PC) ‘A rogistor that holds the address of the noxt instruction to be processed. Memory address register (MAR) | A register that stores the address of where data or an instruction is located in RAM Memory data register (MDR) | A register that stores data or an instruction when itis fetched from RAM, Control unit (CU) ‘A component that sends signals to control the interactions of all other components during the fetch-execute cycle. Current instruction register (CIR) | A register that holds the instruction that is currently being processed ‘Arithmetic logic unit (ALU) ‘A component that performs all calculations and logical operations required during the fetch-execute cycle. ‘Accumulator (ACC) A register that is built into the ALU that is used to store the interim results of calculations ‘Address bus ‘Abus that is used to transmit addresses within the CPU and to, and from RAM. Data bus ‘A bus that is used to tansmit data or instructions within the CPU, and to and from RAM Control bus ‘A bus that is used to transmit control signals that are sent by the control unit. Quad 4.800.000 000 If there are a large amount of frequently used data and instructions stored, it will take longer for the CPU to search through the cache to find the one it is looking for. It could be quicker in this case for the CPU to get the instruction or data from RAM, rather than searching a large amount of data in a large cache to find it. Ce ene Te Ra Cone ee nana ae Lee eee] N » COWL cla cena Roda Moo at eels osteo] ciated Chapter 3 continued ‘There are many other example uses than those given: Barcode It scans a barcode so that the data stored in the barcode can be obtained. Itis used in a supermarket to get the price of a product and as part of a stock control system, Digital camera Tt captures light through a lens and converts it into binary. itis built into a mobile phone to allow the user to photograph items or people. Keyboard Ttallows the user to press keys that have a dosignated ASCII/Unicode value that is converted to binary. itis one of the main methods of input that allows a usor to typo data into a personal computer. Microphone It captures soundwaves and converts them to binary. Itis built into 2 mobile phone to capture the users voice so that it can be heard by the other users, Optical mouse It captures the light that is bounced back from a laser that is shone from the mouse to the surface underneath, to track the mouse's movements. Itis one of the main methods of input that allows a user to select icons and menu options whilst using a personal computer ‘OR code. scanner It uses a sensor or a camera to capture light reflected from 2 OR code and converts it to binary. It can be an application that is downloaded onto a mobile phone and used to SCAN OR codes that store information, e.g. a website link ‘Scanner (2D and 3D) They use sensors to capture light that is reflected from a 2D or 3D object and convert it to binary Itcan be used to scan 3D objects to create a digital copy of them. Touch screen (resistive, capacitive and infra-red) Thy use prossure, conductivity or light to register the touch of a user ona screen. The coordinates of the touch can be calculated It is built into a ticket machine to allow a user to select which ticket they would like to buy. ‘Actuator Itis a component that outputs an action, often a type of movement, that causes another device to operate. It can be used in an automated system to move or tun on/off another device, e.g. alight. Digital light processing (lr) projector It is a device that uses light reflected from millions of little mirrors to output an image. It can be used in a classroom to project {an image onto an interactive whiteboard. Inkjet printer This is a device that squirts liquid ink from nozzles to output a document or image. It can be used in a house to print photographs Laser printer This is a device that uses a rotating drum and powdered toner to output a document. It can be used in an office to print letters. © Cambridge University Press 2021 Dodoma CEM Erol Casteoll sled Chapter 3 continued Light omitting | This is a scroon that usos LEDs as a_| This seroon can bo built into a mobil diode (LED) | backlight to output an image. phone. screen Liquid crystal [This is a device that shines light | This can be used to project an image in display (LCD) | through crystals and then through | a home cinema system. projector —_| a lens to project an image onto a blank wall or screen Liquid crystal [Thisis a screen that shines light | This can be built into a television screen display (LCD) | through crystals to output an screen image ‘Spoaker This is a dovico that outputs sound. | This can bo built into a mobile phono so one user can hear another users voice ‘3D printer | This is a device that builds layers of | This can be used in medicine to create material to output a 3D object. prosthetic limbs Input Any five from: + acoustic accelerometer flow gas humidity infra-red level light magnetic field moisture pH pressure proximity + temperature ‘Any valid example, such as: Light — To automatically turn a car’s headlights on, whem itis dark. Magnetic field — To operate an ABS braking system in a car. Temperature — Ina kettle, to turn off the heating clement when the water is boiling, © Cambridge University Press 2021 Dodoma CEM Erol Casteoll sled Chapter 3 continued Any two from: ‘They are more accurate than a human. They can monitor 24/7 as they don't need to take a break like a human, ‘Their use can mean that humans can complete other tasks that require more thought ‘Their use can stop humans getting bored doing repetitive tasks. Their use means that humans don’t need to go into dangerous environments to monitor and control them. It could help detect when the hard drive is falling through the air and turn the device off, to try to help prevent damage to data RAM Program counter / PC Any three from: + The instruction is sent (o the control unit, + The control unit decodes the instruction by converting it to binary. It does this using an instruction set +... which isa set of all the commands that are understood by the CPU, Two from: + Two instructions can be processed at the same time +... which helps data be processed quicker by the CPU. Primary ‘One mark for each type of storage: + RAM: Programs and data that are currently is use. + ROM: Start-up instructions, such as the BIOS. ‘One mark per each correct sensor To monitor the amount of pollution in a river pH To count the number of competitors who finish a race. [ Magnetic / pressure / Infra-red To detect a person who is approaching an automatic | Infra-red door systom. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 3 continued Any two from: + cD + DvD + Blusray Six from: + A laser is directed at a reflective surface on a disk. + The disk is spun, + A read / write head that contains the laser is moved across the surface of the disk. + The laser burns pits into the surface of the disk. + Itstarts at the eentre of the disk and works outward in a spiral track, + Bach pit represents a binary value. Any one from: They do not have to pay for the hardware to store the data, ‘They do not have the responsibility for the security of the hardware that stores the data, They can access the data and resources using different deviees from anywhere that has an Internet connection. ‘They can increase and decrease the amount of storage space that they need very easily, on demand. Any two from: + They are relying on a third party making sure that their data is safe If they do not do this correctly, they might put their data at risk, If their connection fails or is not available, they will not be able to access their data. + If their connection is slow, this can also mean that accessing their Gattis slow. Any two from: + Iti numerical + Teuses 32 bits + Each section is separated using full stops/ periods / dots, Chapter 4: Software E.g. easier to make an error, harder to debug E.g. casier for people to write programs, more user-friendly interfaces for a range of users Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 4 continued E.g. word processor, database, spreadsheet. Do not allow brand names. To manage the hardware and software and allow these to communicate ‘The application software runs on the operating system. The operating system runs on the firmware. The firmware is loaded by the bootstrap. Exg. create a file or directory, name a file or directory, move a file or directory, put a file directory Software, ex. division by 0, attempt to access memory location not accessible. Hardware, e.g. printer out of paper, pressing a key on the keyboard, The interrupt handler determines where the interrupt goes in the queue, based on the priority. When a FDE cycle finishes, the interrupt queue is checked. If there is a higher level interrupt than the current process, the current process is stored. The ISR for the interrupt is run. When finished, the current process is reinstated 11 uses English-style statements. It needs to be translated to a low-level language to be run, Itis portable / machine-independent Assembly; High-level; Machine code Low-level language: Allows direct manipulation of hardware, reducing the memory that the program uses. Assembler, interpreter and compiler Interpreter - whilst writing the program code, It allows Nasrat to make corrections without having to restart the program e: Compiler ~ Either: Whilst writing the program, because it gives all the errors together so they can all, be corrected before starting the program. (Or: When the program is finished. It can be tested without having to re-compile each time. It produces an executable file - this means the source code does not need to be released (0 it cannot be copied or amended) and the user can run the program without the translator Run-time environment, allows the user to interact with the program, Breakpoints, to stop. the code at specific points and check the variables. Stepping, to run the code one line at atime to check the values, Variable wateh window, displays the variable values while the program runs. ‘The interpreter will stop at an error so that Saria can correct it in real-time and then continue where the program stopped. ‘The compiler will produce an executable file, this means that Saria can distribute the software without having to give users the source code, and it saves time when testing ultiple times as it does not have to interpret the code each time, Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 4 continued ‘One mark for four correct, two marks for 5 correct, three marks for 6 correct, four marks for 6 correct, five marks for all correct, _________[System software [Application software | Word processor “ Defragmentation Operating System Image manipulation System clean-up Database Web browser ‘One mark per bullet An interrupt is a signal that tells the processor its attention is needed. ‘One mark for system software definition, eg, allows the hardware and software to run and communicate, ‘One mark for application software, eg. software that allows the user to perform useful tasks. ‘One mark for an example of each, e.g. system = OS, application = word processor Do not award brand names. It must be clear which type oF software each example refers to. ‘One mark per bullet to max three. allocates memory to processes. Tr moves data between memory. E.g. It fetches data from RAM. Tt stores data in RAM. It prevents two processes from accessing the same memory location, ‘One mark each from: Managing files Handling interrupts Providing an interfac Managing peripherals and drivers ‘Managing multitasking Providing a platform for running applications Managing user accounts, One mark per bullet to max five. + The interrupt handler puts the interrupt in the queue depending on its priority ‘The processor finishes the current FDE cycle. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 4 continued + Ttchecks if there is @ higher level interrupt, if there is it stores the current contents of memory. it then accesses the ISR for that interrupt. when finished it reloads the current contents of memory and continues, + if not, it processes the next instruction, ‘One mark for each completed section: + Operating System + Bootstrap program, (One mark per bullet, max three for low-level, max three for high-level, Low-level language: + Machine code or assembly language + (Machine code) does not need translating for the computer to run the code + Not portable, High-level language: : ten in human-understandable / English language + Needs translating into low-level language before it can be run + Is portable + Ts casier for humans to read / write / debug, ete. ‘One mark per bullet. + Itiseasier for the person to read and write the code «- Because itis in more English-style syntax. Tris easier for the person to debug. Tris portable / machine-independent. so it can be used on different computers, ‘One mark for: to write a more memory efficient program, ‘One mark for translator, compiler or interpreter. One mark per bullet for justific: Justification must match translator, Interpreter: Trruns the code and stops when an error is found this means Qui can correct the error and continue running the program from that position, Qui can add a small section to the program and test it without having to create a complete code that is all syntactically correct. A compiler would report all the ertors at the end 80 Qui cannot test small sections of the program. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 4 continued Compiler: + Qui will get a report of all the syntax errors +... so that he can correct them all before running the whole program without it stopping, ‘One mark per bullet to max six. Qui can an editor to write the code, Pretty printing will colour key words to help identify errors. He can use auto-complete so that he can enter part of a word and it will give him options to select and reduce the chance of errors, Qui can use the run-time environment. to show the output and allow inputs from the user thas error diagnostics and a breakpoint to stop the code at set point to check the values Stepping will run the code one fine at a time to view how the values change and the order the program runs. Quican use the variable watch window +. to see how the values change. One mark per bullet to max eight, Max four for naming functions. + Iallows the user to communicate with hardware. Teruns the hardware It provides a platform for software to run. Te manages files allowing users to ereate/ rename / move files and, and allowing users to ereate / rename / move directories / folders. Tt handles interrupts so that when a device needs the attention of the process it adds it to the interrupt queue and it uses the interrupt service routine to perform the required functions. provides an interface such as GUL command line «+10 allow the user to input data and receive output manages peripherals and devices, Installs device drivers «and sends data to the device / fetches data from the deviee. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 4 continued + Ttmanages memory, allocates memory to running processes, anoids two processes accessing the same memory and moves data between memory, eg. RAM and HDD. manages user accounts «allowing for security / sets username and passwords Chapter 5: The internet and its uses The answer will depend on the students. The answer will depend on the students. There will be an open-ended discussion. It isa text based address for a website Itis a unique address that is given to a device, such as @ computer or a web server. Tris often allocated by a router. It can be statie or dynamic. Protocol; domain name; web page name or file name tis a certificate given to a website company that can be produced to show that the website is authentic and secure. It is stored on the web server and is requested by the web browser when the HTTPS protocol is used. The web browser checks the authenticity of the digital certificate Web browser To store personal data about a user A session cookie is deleted when the web browser is closed. A persistent cookie is deleted only when its expiry date is reached, or itis manually deleted by the user. Cookies build up an online profile that some users believe can be used to target them for criminal activity, such as stealing their identity. Other users think itis an invasion of their privacy to build this kind of online profile. A hacker is a perpetrator who gains unauthorised access to data. Use security methods such as: a firewall automatic software updates strong or biometric passwords two-step verification, Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 5 continued Use anti-malware software to find any malware that may be redirecting website requests and visually checking the web page, Ase, only download data from trusted sources You could check + if the URL at the top of the screen is the correct one + if te siti secured using HTTPS *+ if the website looks like it normally does, such as the usual colours and placement of items. The internet Any one from: + protocol + domain name. Domain name server ! DNS (One mark per each correct term in the correct order: web browser: domain name server: web server; HTTP / HTTPS; HTML. Any two from: It provides an address bar that you can use to type ina URL, It keeps a record of all the web pages that you have visited. allows you to bookmark web pages and set web pages as your favourites Icallows you to open multiple tabs at a time. Ivallows you to navigate between web pages. Session cookie 1k for one bullet, from ‘Transactions that have been recorded cannot be changed, Anyone can view the transactions that have been made. ‘One mark for one bullet from: + A proxy server ean be used. + Users can scan their computers with anti-malware software to prevent it being used as a bot Any three from: ‘The user is encouraged to click an infected link / download this triggers a download of malware onto the user's computer that turns the user's computer into a bot “Multiple bots are created from users’ computers that are all part of @ network. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 5 continued One mark for each of the following shown in the diagram: Data packets are being sent from one computer to another, A packet sniffer has been installed on a device on the route, eg. router. A packet sniffer is examining each packet that passes through it, Router Device 2 Data packets sent to device 2 Packet sniffer installed onto router that examines packets that pass through ‘One mark per each correct line to a max of three. Security solution Description This is a protocol that encrypts data that is sent Firewall ‘across the internet. “This is software that can be used to scan a Antimalware ‘computer for malicious files. This can be hardware or software based and it Access levels ‘examines traffic incoming and outgoing from a computer system or network. This is connected to a user's username and provides information about what data the user is allowed to accass on a system. ‘Two marks (one per method, one per explanation) for two methods (for a total of four marks) from: Phishing: a link sent to a user via email has encouraged the user to type their login details into a fake website Pharming: malicious software has been downloaded onto the user's computer that has redirected the user to a fake website where they have typed their details, Spyware: key presses from the user's computer have been sent to a third party and analysed for patterns revealing login detail Social engineering: a perpetrator has manipulated the user into providing their login details. Brute-force attack: a perpetrator has used software to repeatedly enter password combinations until the correct one is found, Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 6: Automated and emerging technologies This is dependent on the learner, ¢g. it could be the ability to adapt, the ability to learn or the ability to make decisions. This is dependent on the learner as there is no right answer, eg. asking it questions, aaltempting to teach it something new, could test it against a human's output. This is dependent on the learners, as some may consider that they should and some may think otherwise, Digital It reads data from the environment and sends it to an ADC. Infra-red, proximity Data is converted from analogue to digital. ‘The microprocessor It compares the data to its stored value. If itis in range or it matches the stored value, it sends a message to the actuator to open the doors. will run forever oF until the system is tured off, Benefits, 2, + faster response + more accurate + does not need to rest. Drawbacks, 2. + initial cost waintenance costs, ‘may have been programmed incorrectly can be hacked Trcan run all day every day whereas people would have to work in shifis. Iwill be more precise - Which will give more accurate results It may have an initial high cost .. because the hardware and sofware will need purchasing, Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 6 continued + The jobs of the people who usually monitor the weather may be lost +... but new jobs may be created to maintain the system. It is a mechanical device that moves and that simulates human movement. Eg. + manufacturing of an object, eg. car + testing products + moving products. Benefit: e.g. saves people time from having to perform repetitive tasks. Drawback: eg. initial cost may be high, Algorithms control the movement of the ears. Benefits include: more procise and can react faster, therefore safer. Not prone to human error or distraction. People do not need to learn to drive, therefore more people will be able to use the cars, Drawbacks include: risk if the programs are hacked, initial cost will be high: Tr means: a program / computer designed to mimic human behaviour / intelligence. Tt means: an AT program that can adapt its knowledge and/or programming without the need for human interaction Itis to mimic the knowledge of a human expert. E.g, diagnosing illness, troubleshooting computers. Knowledge base - the facts. Rule base - logical statements derived from the knowledge, E.g. a pressure sensor will continuously send data to the microprocessor that is converted to digital, E.g. the microprocessor will compare the data to the stored value / weight. If the value meets (or is greater than) than the stored data it will send a signal to an actuator to open the door, Eg. when the sensor has not detected a person for 5 seconds. E.g. troubleshooting, diagnosties. ‘One mark for each word. An expert system is made up of four parts. The knowledge base is the set of facts. ‘The rule base is set of logical rules. The inference engine applies the two bases to decide what questions to ask next and to work out the response. The interface is the elements that allow the user to input data and to output data to the user, Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 6 continued Any three from: ‘mechanical structure / framework electrical components microprocessors actuators programmable, One mark per bullet to max si. + Infra-red sensors are used and they send a signal to the microprocessor. The signal is converted from analogue to digital ‘The microprocessor compares the signal to its stored distance value «nd if the value is less than the stored distance it sends a signal sa fo an actuator to play the sound und the process is continuous ‘One mark for a description, e.g. Machine learning is when an AI program can change its own data or rules, One mark for an example, e.g. a computer game AI can learn which moves are successful and which are not, e.g. an image recognition system can learn how to recognise objects in aan image, One mark per bullet, max four for advantages, max four for disadvantages. Advantages €2. + Long-term costs may be reduced eg, fewer wages to pay. ‘The factory can work all day every day. Robots may be more precise. Robots will make fewer errors / no human error. New jobs will be created in their maintenance, Disadvantages e.g, + The initial cost will be high People will lose their jobs. ‘They are expensive to fix if broken ‘The robots have limited actions they can perform Iris expensive to change any robotic processes. Ce ene Te Ra Cone ee nana ae Lee eee] N » COWL cla cena Roda Moo at eels osteo] ciated Chapter 6 continued One mark each, ex. + Selfdriving cars + Managing the movement of items in 2 factory, eg. for loading lorries, One mark per bullet to max four. ‘They can employ machine learning. It can be used supervised or unsupervised. Sounds are input and the system is told what users are saying this is repeated many times with different variations, Sounds are input and the system has to categorise them into those that are similar. E-g, harvesting the crops, watering when there is no rain, packaging crops. One mark each, ex. + They are productive/ the farmer can perform other tasks at the same time, + The farmer gets better harvest / erops by keeping them watered without having to check them continually + Fewer accidents / automated system not prone to human error, ‘One mark each, eg. + Initial cost could be very high. + Any problems with the systems will be expensive to fix. + Jobs will be lost. ‘One mark per bullet to max six, eg They can receive input using sensors eg. infra-red to detect movement .. ©. pressure to detect if they are being touched .. ©. acoustic to detect sound, Image recognition can be used to identify what has moved eg. if itis another animal A set of possible movements are stored eg. move head towards the other animal one of these can be chosen depending on the image detected. Speech recognition can be used to identify the sounds recorded «6, the species of an animal and then react, eg. perform an action, Ce ene Te Ra Cone ee nana ae Lee eee] Rect ccaer cell ava mee ates le skeot) Cs-.oleld Chapter 6 continued One mark per bullet to max six, e. Human interaction is not needed sand will not cause fear. They can record the animals’ natural behaviour .. because they will not be influenced by people. Animals might not act naturally because there is a new item present ‘Animals could attack the robots «nd cause damage or hurt themselves, Robots can record all day every day whereas humans will need to stop. Chapter 7: Algorithm design and problem solving An event driven language has code that is only run when an event happens, such as when a button is clicked or an option is selected from a drop-down box. E.g. office software such as word processors and spreadsheets would benefit from aan event-driven language. A computer game would be better written in a procedural or object-oriented language. Tt means splitting a problem / system down into subproblems/subsystems rng nea) peal peed ns Ce ene Te Ra Cone ee nana ae Lee eee] DSU et ccaer Colla Moe) aa Rel eho) T3130 4 Chapter 7 continued Ee. foo Pees Monet ey rn mpare reno password [if username and ff username and Correct, Eo password ered pee Start/Stop (“smo ) ) NX a — Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 7 continued ‘OUTPUT x GN sy Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 7 continued ‘The purpose of pseudocode is to design an algorithm in a non-specific programming language. Any three of: normal, abnormal, extreme, boundary. Extreme tests data that is on the edge of what is allowed and normal tests any values that are allowed. Extreme only tests the valid boundary whereas boundary tests just inside and outside of the boundary. Normal 12345678910 ‘Abnormal “Anything <1 or > 10, or characters, @.g. "a" Extreme 110 Boundary oon Compare to 10; compare to 5; compare to 6; found © Cambridge University Press 2021 DSU et ccaer Colla Moe) aa Rel eho) T3130 4 Chapter 7 continued Compare to b; compare to u; compare to I; compare to p; compare to f; found 2 40 40 (2 40 [52 oe 52 52 [40 52 [40 The inefficient algorithm continues to loop and make comparisons even when all the data isin the correct order. ‘The efficient algorithm stops as soon as the data has been run through once without any changes. ‘Totalling adds the values together, counting it adds one for each new value. ‘Smallest - any number above 200; largest - any number below 20 Eg. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 7 continued E.g, (N.B. works for numbers between 9999 and 9999) Tr means checking that data entered is reasonable and within bounds Any three of: range, length, type, presence, format, check digit. The purpose is to check that data has beon entered accurately. Range check Range check Eg. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 7 continued 5 tis because of the number of (Number of items ~ 1) = 3, will compare all of the items with all of the items Change the comparison from less than to greater than, 6 ‘Compare the first characters in each string, then if they are the same look st the next character in each string. ‘You record variables’ values and outputs. You change the value in a column whenever there is a change. Students’ answers, eg, including a negative number. Stop when you have identified the pattern, Eg. 0 0 oO 1 100 150) 50 160) 10 193 3 3 235) 2 Look at what is output and how it is calculated: + The smallest number input between 10.and 100 + The average of the numbers entered that are between 10 and 100, Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 7 continued Trace table, walk through To demonstrate an understanding of the overall purpose and how this code works. altogether. ‘Takes 10 numbers as input and outputs the largest of the numbers, 0 20 20 50. 70. 40 25 5 The total is 190 The average is 38 0 Outputs the numbers from the one the user enters to 0. Reads in values from the user until they don't enter Y to continue, Records and outputs how many valid numbers are entered - between 10 and 20. Records and outputs how many invalid numbers are entered. It is series of steps that solve a problem, ‘One mark for name, one mark for description: Design: *+ Plan the algorithms for the problem + Decompose the problem using a structure diagram. Ce ene Te Ra Cone ee nana ae Lee eee] Rect ccaer cell ava mee ates le skeot) Cs-.oleld Chapter 7 continued Coding: *+ Write the program code for the program, + Tnelude iterative testing. Testing: + Input data and make sure that the program outputs the correct data, + Input a range of data to check if the program works. ‘One mark per bullet to max two. + Itsplits a system into sub-systems repeatedly. + Itmakes the problem more manageable, + Itidentifies smaller parts that can be programmed independently, ‘One mark per bullet Write the system name in the top box. Split into at least two parts for level 1 Include start options of load game and new game. Include all four movements as input and correct output One possible answer, eg INPUT loft JIM INPUT right IM INPUT up iM INPUT do cee Coe jump co ‘One mark per bullet There is an appropri The value is input. There are four decision boxes with yes and no options. There are process boxes for movemeat. Allines join and all boxes have arrows in and out. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 7 continued Be. / move / INPUT move / AL | - ~ No ao NO_-“smove > —~,_YES _— << ne >| Move right Ce Format / presence / type ‘One mark per bullet + Input of name + Getting length of name + Checking length is 8 or more Outputting appropriate messages. Ce ene Te Ra Cone ee nana ae Lee eee] DSU et ccaer Colla Moe) aa Rel eho) T3130 4 Chapter 7 continued One mark per bullet Initialising values Inputs the correct colours and quantities Updates blue, white and yellow correctly Outputs how many left for each Outputs Continue? each time. Blue left - 5 Continue? Blue left ‘Continue? Ty again Continue? White = 0 Continue? One mark per bullet + Compare 100 with first value + and all successive values in order. + Reportit not found ‘One mark for each swap in order: ‘apple _[pear__[banana [pineapple [orange | peach apple [banana _|pear__|pineapple [orange | peach ‘apple [banana [pear [orange | pineapple | peach apple [banana [pear [orange [peach _| pineapple apple [banana [orange | pear peach [pineapple orange [banana_[orange [peach | pear pineapple ‘One mark for each line number and corrected line. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8: Programming Itis so that they can be used / understood by any programmer and so that programmers can change language easily. This is entirely up to the learners as there are many that could be found, e.g. REPEAT UNTIL, You cannot change the value when the program is running. Ithas an identifier itis a memory location, You can change its value when the program is running, It stores a piece of data, Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8 continued Iisa programming construct where code is run, or not run, depending on a condition. and Pre-condition tests the condition before starting the loop, post-condition runs the code then tests the condition, In pre-condition the code in the loop may never run, in post-condition the code in the loop will at least run once. Count-controlled Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8 continued Initialise the variable to 0. Add the values to the total. Initialise the count variable to 0, Add I to the variable for each itera Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8 continued A selection inside a selection; an iteration in an iteration; a selection in an iteration; an iteration in a selection 12 A funetion returns a value whereas a procedure does not return a value. 6 Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8 continued ‘They split the code into smaller sections. Each seetion has a name that deseribes it A subroutine only needs to be changed once, and it will change every time itis used. ‘Comments ~ they describe what the code does, so other people can understand its purpose Meaningful identifiers - they describe what the variables, et. do so that people can understand their purpose. 31 A variable can store I value whereas an array can store multiple values. It stores different data types whereas arrays can only store one data type. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8 continued I1is so that they can be accessed next time the program loads, oF so that the d lost when the program stops running. + Open the file + Write the data + Close the file If Lis less than 2 If 6is greater than 3 1f 999 is greater than or equal to 998 IF 34 is ess than or equal to 77 False False False True Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8 continued ‘One mark per bullet to max two. + They are both memory locations. + They can both store an item of data. + They both have an identifier A variable can change while the program is running whereas a constant cannot change while the program is running. ‘One mark per bullet + Taking two values as input and storing them. + Adding the inputs together + Multiplying the inputs together. + Providing both outputs. Eg. Pre-condition To loop the number of times represented by the variable, quantity Three of: quantity, largest, total, smallest. (One mark per bullet Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8 continued Changing while to for Tneluding count=0 in the for statement Looping until quantity (or quantity +1) Removing counter=counter +1 Ending with Next. (One mark per bullet. + Looping 20 times + Tnputting a number + Storing in appropriate array index Eg. ‘One mark per row: Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8 continued ‘One mark per bullet. + Looping through first index 10 iterations. *+ Looping through second index 20 iterations, + Generating a random number between | and 100. + Storing in the correct indices. Eg. Tt returns a value, ‘One mark per bullet to max seven, Function declaration with identifier move «taking an appropriate parameter. Reading input from the user and storing the result, Checking if the move entered is left decreasing the x coordinate. Checking if the move entered is right « inereasing the x coordinate, Returning the x coordinate in both left and right Looping until there is. valid input. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 8 continued ‘One mark for each box. Comments: give people information ubout how the program works / the meaning of each section of code, ‘Meaningful identifiers: give people information about the purpose / stops people confusing different variables. One mark per bullet + It declares the procedure with identifier and no parameters. It opens the file, number.txt. Tt reads the data from the file. closes the file It loops 12 times Tr outputs the 12 times table for the data read Chapter 9: Databases This is dependent on the site chosen, but if data is stolen then the perpetrators may be able to access other accounts and card details This is dependent on the company, but the damage could be financial, reputational, ete Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 9 continued Eg. Boolean’ True Integer 1 Text “Hello” Character F Real 2.36 Date/time 5/5/2021 ‘A table has several fields. Bach field is one piece of information. A row of data about one object/tem is called a record, To uniquely identify each record Eg Username Text/alphanumeric Password Text/alphanumeric Online name Textalphanumeric Date account created Date/time Number of friends Integer E.g. Username, or adding an ID, eg. user ID OSE Saturn Chocolate Vanilla Fudge Peanuts Nuts Jazz Fruit Signet Fudge SELECT Cost FROM PRODUCTS SELECT ID Number, Name FROM PRODUCTS Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 9 continued SELECT Name, Cost, Quantity in stock FROM PRODUCTS 596 Computer Science Programming 2 806 Computer Science Programming 2 596 Computer Science Pass 123 Maths Pass 023 Maths Pass 806 Computer Science Pass 59%6 Science Pass SELECT Test name, Percentage, Grade FROM MARKS WHERE Percentage > 50 SELECT Student TD, Subject, Percentage FROM MARKS WHERE SUBJECT = "Science" SELECT Student TD, Test name, Percentese FROM MARKS WHERE Percentage <= 25 203 [22 [11/12/2019 ar [1s [11272019 wig [13:00 [43 tiiz019 [15:00 [41 tiiz201e [18:00 [60 11/12/2019 11/12/2019 11/12/2019 11/12/2019 12/12/2019 SELECT Time PROM WEATHER WHERE Date = 12/12/2019 AND Humidity > 50 Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 9 continued SELECT Wind speed, Temperature WHERE Wind speed < 15 OR Wind speed > 20 W.2 18 12/12/2019 18.4 20 12/12/2019 20.3 2 11/12/2019 23.7 15 11/12/2019 23.9 16 11/12/2019 24.0 B 11/12/2019 11/12/2019 13:00 23.763 1112/2019 15:00 240 © 4t 1112/2019 18:00 23.960 1112/2019 10:00 20.3 59 12/12/2019 15:00 18.4 52 12/12/2019 18:00 17.2 «48 SELECT Date, Wind speed, Humidity FROM WEATHER ORDER BY Wind speed SELECT Date, Time, Temperature FROM WEATHER ORDER BY Humidity DESC SELECT Temperature, Wind speed, Humidity PROM WEATHER ORDER BY Temperature DESC 135.71 SELECT COUNT (FirstName! FROM ORDERS WHERE PiratName Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 9 continued SELECT SUM(ToEsICost) ROM ORDERS WHERE Nusberttems >= 5 SELECT COUNT (Nunbert tens) RoW ORDERS SHBRE Botalcost > 50.0 ‘Sum adds together the values, Count identifies how many records there are. ‘One mark per definition. Record the completed fields for one object / item. Example: all the data about one student. Field one piece of data, Example: Date of birth, ‘One mark per description and example to max four. Boolean: can only be 2 values Example: true. Real: decimal number. Example: 23.5 Date/time: a date or a time, Example: 1/1/1900. ‘Text: one or more letters, symbols and/or numbers. Example: "hello!" One mark per bullet ID (or other appropriate key field), data type Integer / Text Screen number, data type Integer /‘Text Film, data type Text / Alphanumeric Date, data type Date / Time ‘Time, data type Date / Time SeatsSold, data type Integer Primary key is ID (or other appropriate key field defined), Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 9 continued 6 7 (One mark for definition, e.g. A unique identifier. One mark for Appointment ID. (One mark for first correct, one mark for remainder correct uP Cut AD Cut and dry AD Colour uP Cut and dry uP Cut AD Colour (One mark for each statement, SELECT Customer first name, Customer last name FROM APPOINTMENTS WHERE Date = 1/2/2020 (One mark for each statement, SELECT COUNT (Employee ID) FROM APPOINTMENTS WHERE Employee ID = "JP" (One mark per bullet Sales ID: integer Date: date / time Customer ID: text Quantity bought: integer Total Cost: real (One mark for one correct, two marks for all correct in the correct order. 3/3/2020 1GHF2 3/3/2020 1GHF2 4/4/2020 1GHF2 (One mark for each completed statement. SELECT Customer ID, Total Cost FROM SALES WHERE Total Cost > 2 Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 9 continued One mark for one correct, one mark for all correct and in the correct order. 12 151 13 2B (me mark for each completed statement SELECT suM(Quantity bought) PROM SALES WHERE Date = 4/4/2020 (One mark for each completed statement SELECT SUM(Total Cost) PROM SALES Chapter 10: Boolean logic In Boolean, values are either true (1) or false (0). In a computer, if there is electricity that means | and if there is no flow of electricity that means 0. A logic gate takes one or more inputs as a Boolean value (or values) and outputs a value. All digital computers represent data in binary form with Os and Is, so they would not be able to operate without logie gates. input 4>e- Output Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 10 continued Input 1S Output Input 2—)_ > " ma) Ap) X =A XOR B Q =(AOR (NOT BAND) X =((A AND B) OR (A NAND ©) Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 10 continued X =((NOT A AND NOT B) OR (NOT A AND B)) Ce ene Te Ra Cone ee nana ae Lee eee] N » COWL cla cena Roda Moo at eels osteo] ciated Chapter 10 continued [pe Jo [Re [Werkspece [2] To contol the flow ofeletrcty input Tour Inpur2—|_}~O#Ps* Input 1 N ety) o-Onton ‘One mark for each correct expression for each output (max three), one mark for joining each expression with OR. X =((NOT A AND NOT B) OR (A AND NOT B) OR (A AND B)) Ls, ~ / ‘One mark for cach correct AND gate with correct inputs. ‘One mark for both correct OR gates with correct inputs. A »\ / ‘One mark for each correct expression for each output (max four), one mark for joining each expression with OR. Z =((NOTS AND NOT T AND P) OR (NOT S AND T AND NOT P) OR (SAND NOT T AND NOT P) OR (S AND NOT T AND P)) (One mark for correct AND expression, one mark for correct NOR expression, fone mark for joining these with NAND. Y =((NOT L AND M) NAND (L NOR N)) Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 10 continued Award: Foor mark for 8 ones outputs The asks for 60 7 cont outputs Two marks for 4 or 5 correct outputs One mark for 2 or 3 correct outputs, X =((NOT M AND NOT H) OR (T AND H) ‘One mark per each correet logic gate with correct inputs. Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 11: Programming scenarios practice ‘There will gaps in the data that you need to tackle the problem and going back later may be costly, time consuming and difficult to implement. This is dependent on the student Inputs, processes and outputs E.g. an action, a modification of a value Eg, validation, appropriate messages, comments Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 11 continued Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 11 continued Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 11 continued Ce ene Te Ra Cone ee nana ae Lee eee] Dodoma CEM Erol Casteoll sled Chapter 11 continued Ce ene Te Ra Cone ee nana ae Lee eee]

You might also like