100% found this document useful (3 votes)
3K views81 pages

Cambridge IGCSE Computer Science 0478 Workbook

Cambridge IGCSE Computer Science 0478 Workbook

Uploaded by

Mehul Gupta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
100% found this document useful (3 votes)
3K views81 pages

Cambridge IGCSE Computer Science 0478 Workbook

Cambridge IGCSE Computer Science 0478 Workbook

Uploaded by

Mehul Gupta
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF or read online on Scribd
You are on page 1/ 81
Cambridge Ices 5 Computer Science ( Workbook David Watson Helen Williams © ERNE Cambridge [cess Computer Science ( Workbook David Watson Helen Williams 6 BORER Hachette UK's policy isto use papers that are natural, renewable and recyclable products and made from wood grown in sustainable forests The logging and manufacturing processes are expected to conform to the environmental regulations of the country of origin. (Orders: please contact Bookpoint Ltd, 130 Park Drive, Milton Park, Abingdon, Oxon OX14 ASE, Telephone: (44) 01235 827720. Fax: (44) 01235 400454, Email [email protected] Lines are open from 9 a.m. to5 p.m., Monday to Saturday, with a 2i-hour message answering service. You can also order through our website: www hoddereducation.com © IGCSE is the registered trademark of Cambridge international Examinations. This text has not been through the Cambridge endorsement proces. © David Watson and Helen Williams 2016 First published in 2016 by Hodder Education, ‘An Hachette UK Company Carmelite House 50 Vietoria Embankment London ECaY 0DZ www hodderedueation.com Impression number10. 987654321 Year 2019 2018 2017 2016 All rights reserved. Apart from any use permitted under UK copyright law, no part of this publication may be reproduced or transmitted in any form or by any means, electronic or mechanical including photocopying and recording, or held within any information storage and retrieval system, without permission in writing from the publisher or under licence from the Copyright Licensing Agency Limited. Further detail of such licences (for reprographic reproduction) may be obtained from the Copyright Licensing Agency Limited, Saffron House, 6-10 Kirby Street, London ECIN aT, Cover photo © Seanral—Fotolia IMlustrations by Aptara Inc. Typeset by Aptara, nc. Printed in the UK. ‘A catalogue record for this title is available from the British Library. ISBN: 978 1471 86867 2 Contents 1 Binary systems and hexadecimal 2 Communication and internet technologies 3 Logic gates and logic circuits 4 Operating systems and computer architecture 5 Input and output devices 6 Memory and data storage 7 High-and-low level languages 8 Security and ethics 9 Problem-solving and design 10 Pseudocode and flowcharts 11 Programming concepts 12 Data structures: arrays and using pre-release material 13 Databases 26 30 38 53 59 65 68 rey (1) Binary systems and hexadecimal 1 Convert the denary number 165 into: [3 marks} a binary b hexadecimal 2a Convert the following binary number into denary: [6 marks] 01110110 b Convert the following hexadecimal number into denary: SF ¢ Convert the following binary number into hexadecimal: 101011000100 d_ Convert the following hexadecimal number into binary: 3ED @ cambridge cst computer scence Workbook Photocopying prohibited 1 Binary systems and hexadecimal 3a How many megabytes (MB) of storage would be needed to store 800 photographs each of which are 16 MB in size? [2 marks] b_ Write your answer from part a in gigabytes (G8). [2 marks] 4 The ASCII code for ‘A’ is 65 and for ‘a’ is 97. a Write these denary values in 8-bit binary: [2 marks] i 65 b Predict the denary ASCII code for 'V' and 'V': [2 marks] iv © Write the two denary values in part b in 8-bit binary format: [2 marks} iw Photocopying prohibited Cambridge IGCSE Computer Science Workbook °e 1 BINARY SYSTEMS AND HEXADECIMAL d_ Using your answers to part a and part b, suggest an easy way of finding the ASCII binary code for a lower case letter (e.g. ‘mm’ if the ASCII code for the upper case letter (e.g. ‘M’) is known. [2 marks] 5 A computer system uses binary codes for letters of the alphabet as follows: A= 10,B=11,C=12, 33,Y 4,2 = 35 a Write the denary value for binary using an 8-bit register: [1 mark] b To convert the binary code for ‘x’ to the binary code for ‘x’, all the bits in the 8-bit register in part a are moved (shifted) two places to the right. i Write down the contents of the 8-bit register after the bits have been moved to the right. [2 marks] ii Convert the binary value in part bi into denary: [1 mark] the denary values for the following two letters using the method described in [4 marks] 3 Cambridge IGCSE Computer Science Workbook Photocopying prohibited 1 Binary systems and hexadecimal 6a Describe how hexadecimal notation is used in the following: 16 marks} i MAC addresses ii Memory dumps b Using the ASCII table (Figure 1.7) on page 12 in the Cambridge IGCSE® Computer Science textbook, write down what web address/URL is being represented below: [3 marks] %77°%77%77 %2E%AB%26%53%73%74%75%64%79$20%62 YGF % GF %6B%73%2E%63 OF % 2E%75%6B 7a Convert the denary number 44801 into hexadecimal. [2 marks] b Convert the hexadecimal number in part a into a 16-bit binary number. [2 marks] Photocopying prohibited Cambridge IGCSE Computer Science Workbook e 1 BINARY SYSTEMS AND HEXADECIMAL 8a Explain the two parts that make up a typical MAC address. [2 marks] b AMAC address can be termed either UAA or LAA. Give two reasons why MAC addresses need to be changed when using LAA. [2 marks] 9 An 8bit register is used to control a paint spray gun. Each position in the register refers to a specific function: paint levels | paint levels | spray gun | spray gun _| red paint | green paint | blue paint | yellow paint areOK [are low _| switched on | switched off | chosen | chosen [chosen _| chosen A 1 value in the register indicates that a specific function is ON; a 0 value indicates it is OFF. For example: r}o}rfo}rj oj1rjo indicates: * all paint levels are OK *+ spray gun is switched on * red and blue paints have been selected. ‘a What does the following register indicate: [3 marks] o/ijolrfojo}oj1 ° Cambridge IGCSE Computer Science Workbook Photocopying prohibited 1 Binary systems and hexadecimal b What would be the contents of the 8-bit register if the following conditions existed: [3 marks] « all paint levels are OK + the spray gun is switched off ‘+ red and green paint had been selected? ns would be represented by: 000000007 [1 mark] Describe what would happen if the register contained: 11111111 [1 mark] 10 Six questions are shown on the left and eight numerical values are shown on the right. By drawing arrows, connect each question to its correct numerical value (two of the numerical values are not used). [6 marks] ‘What is the denary value of the 10 hexadecimal digit 7 ‘What is the denary value of the R binary number 000111007 1" If the download speed for broadband is 64 megabits per oD second, how long would it take to download a 96 megabyte file (in seconds)? 2 If 2*= 1 terabyte (TB), what is the value of x? 7 What is the hexadecimal value of the denary number 507 Ey ‘How many bits are there in two bytes of data? [40 Photocopying prohibited Cambridge IGCSE Computer Science Workbook e 1 BINARY SYSTEMS AND HEXADECIMAL " ‘a. Trace through the flowchart for the following two values: i 220 [4 marks] Number x D ‘OUTPUT cont \ue on the next page... ° Cambridge IGCSE Computer Science Workbook Photocopying prohibited 1 Binary systems and hexadecimal b State the function of the flowchart in part a. [7 mark] Photocopying prohibited ‘Cambridge IGCSE Computer Science Workbook to) 1 BINARY SYSTEMS AND HEXADECIMAL 12a The HTML value # FF 0000 represents the colour red, value #00 FF OO represents the colour green, and value #00 00 FF represents the colour blue. i If the colour orange requires value ‘FF" for the red hue and value ‘80’ for the green hue, what is the HTML representation for orange? (1 mark] ii If the colour tan requires value ‘81’ for the red hue, value ‘89" for the green hue and the HTML representation for tan? [1 mark] value ‘04" for the blue hue, what i b Describe how HTML is used when developing web pages. [3 marks} ¢ An internet service provider offers the following specifications: + download speed: 80 megabits per second data transfer rate * upload speed: 16 megabits per second data transfer rate i John wishes to download a movie which is 650 megabytes (650 MB) in size. Calculate how long it would take (in seconds) to download the movie. [2 marks} ii John also wishes to upload 30 photographs onto a social media website. Each photograph is 15 megabytes (15 MB). Calculate how long it would take to upload the 30 photographs (in seconds). [2 marks] © Cambridge IGCSE Computer Science Workbook Photocopying prohibited 1 Binary systems and hexadecimal 13 By drawing arrows, connect each term on the left to its correct description on the right. [5 marks] 14 A computer uses a binary system known as Binary Coded Decimal (BCD). In this system, each denary digit (0 to 9) is represented by a 4-bit binary value: 84 21 a Give the 4-bit binary codes for the digits 9 and 6. [2 marks] 9 e424 6 b_ Which denary numbers are represented by the following 4-bit binary codes: [4 marks} 84 21 84 21 1}o}ojo o}1}oja Photocopying prohibited ‘Cambridge IGCSE Computer Science Workbook oO 1 BINARY SYSTEMS AND HEXADECIMAL © What is the largest denary number that can be represented by two bytes using this BCD system? [1 mark) d_Using normal binary notation, what is the largest denary number that could be represented by two bytes? [2 marks) fe Suggest a use for the BCD system. [1 mark] 15 Write down a series of steps that could be used to convert a denary number into a hexadecimal number. Your steps should allow somebody to follow them clearly to give the correct converted value. [7 marks] @ Cambridge IGCSE Computer Science Workbook Photocopying prohibited Communication and internet technologies 1 Name the type and method of data transmission being described below: a. Data transmitted in one direction only; one bit at a time over a single channel or wire. [2 marks] b Several bits of data transmitted in both directions at the same time over several channels or wires. [2 marks] ¢ Data transmitted in both directions, but not at the same time, along a single channel or wire. [2 marks} 2.a_ Describe how it is possible to ensure data arrives correctly identified at its destination when using asynchronous data transmission. [2 marks] b Describe how it is possible to ensure that data is received in the correct groups when using synchronous data transmission. [3 marks] ©. Give one advantage and one disadvantage of using synchronous data transmission. [2 marks] Advantage: .. Disadvantage Photocopying prohibited Cambridge IGCSE Computer Science Workbook ® 2. COMMUNICATION AND INTERNET TECHNOLOGIES 3. Give the meaning of the term USB. [1 mark) b Indicate with a tick (/) which of the following statements about USB connections are true: ‘Statement about USB connections Tue) All the wires in a USB connector are used in data transmission The maximum cable length in a USB connection is 2 metres Devices plugged into the computer using the USB connection are automatically detected ‘The USB connection has become the industry standard for most computers The user will always be prompted to download a device driver when the device is plugged in to the computer © Give two examples of devices which can be connected to a computer using a USB connection. {5 marks) [2 marks] 4a. Asystem uses even parity. Indicate which of the following bytes has even parity: [3 marks] b_ Explain why parity checks are used. [1 mark] ® Cambridge IGCSE Computer Science Workbook Photocopying prohibited 2 Communication and internet technologies ©. Nine bytes of data were transmitted from one computer to another computer. Even parity was used by both systems. An additional byte, called the parity byte was also sent at the end of the transmission. The following table shows the nine bytes and parity byte following transmission: paritybit|bit2 [bits [bia [bits [bite [bit7? [bits bye? 1 1 1 ° 1 1 1 ° byte2 1 ° 0 ° ° 1 ° ° byte3 [0 1 1 1 ° 0 1 ° bytes 0 1 1 1 1 ° 1 1 bytes 1 1 o ° ° 1 1 0 bytes [0 1 1 ° 1 1 ° 1 byte? 1 ° ° 1 0 ° ° 0 bytes 0 1 1 1 1 1 0 1 byte 9 0 0 0 0 1 0 0 1 parity byte: | 0 ° 1 1 1 1 ° 0 i One of the bits has been transmitted incorrectly. Indicate which bit is incorrect by iving its bit number and byte number: [2 marks] bit number: byte number: ii Explain how you arrived at your answer to part ci. [3 marks] ili Write down the corrected byte: [1 mark] iv Describe a transmitted incorrectly. [2 marks] yn where a parity check would not identify which bit had been Photocopying prohibited Cambridge IGCSE Computer Science Workbook © 2. COMMUNICATION AND INTERNET TECHNOLOGIES v_ Name and briefly describe another method to check if data has been transmitted correctly. [2 marks] 5 Which internet terms are being described below? [5 marks] Companies that provide the user with access to the internet; a monthly fee is usually charged for this, service ‘A unique address that identifies the location of a device which is connected to the internet ‘Aunique address that identifies the device that is connected to the internet A set of rules that must be obeyed when transferring files across the internet Software that allows a user to display a web page on ‘their computer screen; they translate the HTML from the website 6 a HTMLis made up of structure and presentation. Explain the difference between these ‘two terms. [3 marks] Structure: b Indicate how you would know whether or not a website was secure. [1 mark] ® Cambridge IGCSE Computer Science Workbook Photocopying prohibited 2 Communication and internet technologies 7 Look at the following two HTML parts: Part A Part B — er Segoe oe ie PRE DS, wee a a Which of the above parts shows the .css file? (1 mark] b Using parts A and 8 from above, give two examples of tags. [2 marks} ¢ Show how a tag is closed. (7 mark] _ Explain why there are three groups of data i the color definition. [7 mark] Which number base is used to represent values in the color definition? [1 mark) Photocopying prohibited Cambridge IGCSE Computer Science Workbook @ (3) Logic gates and logic circuits 1 Whic logic gates have the following three truth tables? [3 marks] =|=Jelos x 1 1 1 o =Te]=e fe siatalohe =|=Jejos x o 1 1 1 =|=Jelos= 2 Complete the truth table for the following logic circuit [4 marks] re : —)>-* [> : ee 7 3a Write the following statement as a logic statement: [3 marks] Xis 1 if A and B are on or if B is off and Cis on © Cambridge IGCSE Computer Science Workbook Photocopying prohibited 3 Logic gates and logic circuits b Draw the logic circuit to represent your statement in part a. [4 marks] afte a} —+« ce 4a Complete the truth table for the following logic circuit: [2 marks} A D> _aae D> A |B | Working area x ojo oi 1 [0 oi b Which single logic gate is represented by the truth table in part a? [1 mark] Explain why a single logic gate is often replaced by a logic circuit such as the one shown. in part a. [1 mark] Photocopying prohibited Cambridge IGCSE Computer Science Workbook © 3 LOGIC GATES AND LOGIC CIRCUITS 5a Complete the truth table for the following logic circuit: [4 marks] DD > D4 A B c ‘Working area x [1 mark] 6 a Complete the truth table for the following logic circuit: [4 marks] SP yy. D> ® Cambridge IGCSE Computer Science Workbook Photocopying prohibited 3 Logic gates and logic circuits A |B |C | Working area x o jo o jo ft o |1 jo o |r ft 1 |o Jo 1 jo |4 1 it jo roir fa [2 marks] 7 a Write down the logic statement to represent the following logic circui — : a —LD- [3 marks] Photocopying prohibited Cambridge IGCSE Computer Science Workbook e 3 LOGIC GATES AND LOGIC CIRCUITS b_ Draw the logic circuit which corresponds to the following truth table: [4 marks} A B c x ° ° 0 1 ° ° 1 0 ° 1 0 1 ° 1 1 1 1 0 ° 1 1 0 1 0 1 1 0 1 1 1 1 1 ate s—}— x ce 8 A chemical process is monitored using a logic circuit. There are three inputs to the logic circuit representing the parameters being monitored in the chemical process. An alarm, X, will give an ‘output value of 1 depending on certain conditions. The following table describes the process conditions being monitored: Parameter description Parameter | Binary Description of condition value reaction temperature T 0 ‘temperature > 120°C 1 temperature <= 120°C Pressure of CO gas evolved | P 0 pressure > 2 bars, 1 pressure <= 2 bars ‘acid concentration A ° acid concentration > 4 moles 1 ‘concentration <= 4 moles An alarm, X, will generate the value 1 if: * either temperature > 120°C and acid concentration <= 4 moles + or temperature <= 120°C and gas pressure <= 2 bars * or acid concentration > 4 moles and gas pressure <= 2 bars @ Cambridge IGCSE Computer Science Workbook Photocopying prohibited 3 Logic gates and logic circuits a Write the logic statement to represent this system. [3 marks} b Draw the logic circuit to represent this system. [7 marks} 7} ae x pt ¢ Complete the truth table to represent this system. [4 marks] T [A [P| Working area x o 0 0 ojo it o 1 0 o 4 7 1 0 (0 1 0 {ft 1 1 [0 1 1 7 Photocopying prohibited Cambridge IGCSE Computer Science Workbook 8 3 LOGIC GATES AND LOGIC CIRCUITS 9 A safety system uses the input from three sensors A, B and C. The binary values from these sensors form the input to a logic circuit. Sensor A. Sensor 8 ‘Output, X, from logic circutt Sensor C The output, X, from the logic circuit is 1 if: seither Ais 1 andBis1 sor AisOandCis1 sor — BisOandCist ‘a Draw the logic circuit to represent the above system. [7 marks] tex oo b Complete the truth table for the above system. [4 marks} BC | Working area x o jo jo 0. |0 1 0 1 ° 0 1 1 1 0 i/o 1 0 1 1 1 0 1 1 1 ® Cambridge IGCSE Computer Science Workbook Photocopying prohibited 3 Logic gates and logic circuits © For safety reasons, the sensors feed into three different logic circuits (numbered 1, 2 and 3) which produce the outputs X, Y and Z. These three outputs then form the inputs to another logic circuit that has the output, Q. The three logic circuits are connected to this extra logic circuit as shown below: |. [Riiepeg | ovrourx reat inputs : —D Fea outeuty tee [Lf Lo9 sensors [_Cu? ) Q AB oe Toa] ovour2z nis Complete the truth table for this system. (4 marks] x [¥ |Z | Working area Q ojo (0 o jo it ° |) (0 . 7 i 1 [0 0 1 [0 9 a) 1 |) 0 Photocopying prohibited Cambridge IGCSE Computer Science Workbook 8 Operating systems and computer architecture 1 Give six functions of a typical operating system (OS). [6 marks) 2a Describe three different types of interrupt. [3 marks} 1 b What is meant by the term buffer? [1 mark] ©The flowchart on the opposite page shows how buffers and interrupts are used when the processor sends data to a printer. Some of the items are missing from the flowchart. m numbers only, complete the flowchart using the following list of items: [6 marks] Item number __| Item contents of printer buffer emptied to printer current task is suspended while interrupt is serviced data to be printed out is sent to the printer buffer processor continues with its current tasks ‘processor continues with current tasks while printer buffer is emptied when all the data is printed, printer buffer becomes empty ® cambridge cst computer scence Workbook Photocopying prohibited 4 Operating systems and computer architecture Fay data be sent to printer? Interrupt signals sent to request more data to be Sent to printer I 3.a_ Name three types of bus used in the von Neumann architecture. [3 marks} b Name three types of address used in the von Neumann architecture. [3 marks] Photocopying prohibited Cambridge IGCSE Computer Science Workbook 8 4 OPERATIN |G SYSTEMS AND COMPUTER ARCHITECTURE YS ) ject «Reject +1 No Sum © Mark + Sum Photocopying prohibited Cambridge IGCSE Computer Science Workbook e 9 PROBLEM-SOLVING AND DESIGN a What are the rules for a mark to be accepted? [2 marks] b What value terminates the input? [1 mark] Use this data and the trace table below to dry run the algorithm. [4 marks) 17, 35, 24, ), 67, 82, 97, -21, 45, 23, -1, 99 why this is an effective solution to adding up marks and point out any improvements that could be made. [3 marks] o Cambridge IGCSE Computer Science Workbook Photocopying prohibited (0) Pseudocode and flowcharts 1 What values will be stored in the following variables when the assignment statements below are completed? [5 marks} age © 21 Nane « "Richard" Value +18 +2 Sum Value + Age Flag | True Age.. Nane. value. sun.. Flag. 2 Write down two types of conditional statement and for each one show how you would select someone whose age was either 10 or 20. [6 marks} Photocopying prohibited Cambridge IGCSE Computer Science Workbook o 10 PSEUDOCODE AND FLOWCHARTS 3.a Write down three different types of loop structure. [3 marks} b Here are three problems. For each one, choose a different loop structure for your pseudocode solution. i Input 10 numbers and print out their total. [6 marks] ii Input some numbers and calculate their total, an input of -1 stops the process. [6 marks] iii, Input some numbers and calculate their total, stop when the total is greater than 20. [6 marks] @ Cambridge IGCSE Computer Science Workbook Photocopying prohibited 10 Pseudocode and flowcharts 4a Write down two different statements that can be used for input. [2 marks] b Write down two different statements that can be used for output. [2 marks] 5 Write a pseudocode algorithm to check the level of stock, Stocktevel, and output 'Reorder' when the value falls below 10. [2 marks] 6a Write a pseudocode algorithm to input 20 numbers and find the average of the positive numbers. [7 marks} b_ Explain how you would change your algorithm to reject any negative numbers. [2 marks] Photocopying prohibited Cambridge IGCSE Computer Science Workbook °o 10 PSEUDOCODE AND FLOWCHARTS 7 Seven examples are shown on the left and four types of statement are shown on the right. Draw lines to connect each type of statement to the example(s) it applies to. [7 marks] 8 Four flowchart symbols are shown on the left and four descriptions are shown on the right. Draw lines to connect each symbol to the correct description. [3 marks] QUQO @ Cambridge IGCSE Computer Science Workbook Photocopying prohibited 10 Pseudocode and flowcharts 9.4 Drawa flowchart to input 20 numbers and find the average of the positive numbers. [7 marks] Photocopying prohibited Cambridge IGCSE Computer Science Workbook ° 10 PSEUDOCODE AND FLOWCHARTS b_ Explain how you would change your flowchart to work for 30 numbers that are between 0 and 100. [3 marks} @ Cambridge IGCSE Computer Science Workbook Photocopying prohibited (1) Programming concepts 1 Five descriptions are shown on the left and five data types are shown on the right. Draw lines to connect each data type to the correct description. [4 marks} ‘Only two values TRUE and FALSE Integer A single character Real ‘A whole number Boolean ‘A number with a fractional part String Several characters char 2 Explain, using examples, when you would use a variable and when you would use a constant. [4 marks] 3 State, giving reasons, whether these data stores should be variables or constants. [6 marks} a. Average Mark b Number of months in a year Number of pupils in a class Photocopying prohibited Cambridge IGCSE Computer Science Workbook ° 11 PROGRAMMING CONCEPTS 4a Here are three problems. For each one, write an efficient program to solve the problem. i Input eight whole numbers and print out their total. [6 marks] ii Input some whole numbers and calculate their total, an input of ~1 stops the process. [6 marks] iii Input some whole numbers and calculate their total, stop when the total is greater than 10. [6 marks] o Cambridge IGCSE Computer Science Workbook Photocopying prohibited 11 Programming concepts ive a set of test data that you could use for each program, [3 marks} Explain whether you would need to make any changes to your programs if real numbers were used instead of whole numbers, [2 marks} 5.a Write a program to input 10 numbers and find the average of the negative numbers. [7 marks] b Explain how you would change your program to reject any positive numbers. [2 marks} © Give a set of test data that you could use for the program. [1 mark] Photocopying prohibited Cambridge IGCSE Computer Science Workbook o Data structures: arrays and using pre-release material 1 Explain what the terms below mean when used about arrays. [6 marks) Name: Size: Element: .... Type: .. Dimension: 2 Explain, using an example, when you would use an array. [3 marks] 3 Using a high-level programming language, declare arrays to be used in the following situations. a The names of 20 students. [1 mark] b_ The marks of 200 students. (1 mark) © Whether 30 students have enrolled or not. [1 mark] © cambridge cst computer Science Workbook Photocopying prohibited 12 Data structures: arrays and using pre-release material 4a Here are three problems. For each one, write an efficient program using an array to solve the problem. You can extend your program for each problem. i Store the number of enquiries made each day for a week. [6 marks] ji Find the day with the most enquires and the one with the least enquiries. [6 marks] ili Find the total number of enquiries for the week and the average number of [6 marks] b Give a set of test data that you could use for these programs. [1 mark] Photocopying prohibited Cambridge IGCSE Computer Science Workbook ° 12 DATA STRUCTURES: ARRAYS AND USING PRE-RELEASE MATERIAL You will need to use the pre-release material for your examination to answer the following questions. 5.a Write an algorithm, using pseudocode for task 1. [6 marks} b Write an algorithm, using pseudocode for task 2. [6 marks} @ Cambridge IGCSE Computer Science Workbook Photocopying prohibited 12 Data structures: arrays and using pre-release material © Write an algorithm, using pseudocode for task 3. [6 marks] For task 3 use a flowchart to show the algorithm. [6 marks] Photocopying prohibited Cambridge IGCSE Computer Science Workbook @ 12 DATA STRUCTURES: ARRAYS AND USING PRE-RELEASE MATERIAL 6a Choose three sets of test data for task 1: normal, abnormal/erroneous and boundary. [3 marks] Normal: b Choose three sets of test data for task 2: normal, abnormal/erroneous and boundary. [3 marks} Normal: © Choose three sets of test data for task 3: normal, abnormal/erroneous and boundary. [3 marks] Normal: @ Cambridge IGCSE Computer Science Workbook Photocopying prohibited 12 Data structures: arrays and using pre-release material 7a Draw and complete a trace table for task 1. Use your normal data for the trace. [5 marks] b Draw and complete a trace table for task 1. Use your abnormal data for the trace. [5 marks] Photocopying prohibited Cambridge IGCSE Computer Science Workbook @ 12 DATA STRUCTURES: ARRAYS AND USING PRE-RELEASE MATERIAL 8a For every variable you have used in your program(s) for tasks 1, 2 and 3, write the variable declaration and explain why you have used this variable. [6 marks] b For every constant you have used in your program(s) for tasks 1, 2 and 3, write the variable declaration and explain why you have used this variable. [3 marks} For every array you have used in your program(s) for tasks 1, 2 and 3, write the variable declaration and explain why you have used this variable. [3 marks} @ Cambridge IGCSE Computer Science Workbook Photocopying prohibited Databases 1. Give three benefits of using databases. [3 marks] 2. Explain the following terms used about databases. [4 marks] Table: Record: Primary key: 3. Aschool keeps a database table (TEXTBOOK) of all the textbooks that are available for student use. The following information is stored for each set of books: the name of the textbook, the ISBN, the authors, the number of copies available for use, the subject it is used for. a. Select names and data types for each field in the table. [5 marks] b i Name the fields that should be verified [1 mark] Name the fields that should be validated. [1 mark] Photocopying prohibited Cambridge IGCSE Computer Science Workbook @ 13. DATABASES © Which field would you choose for the primary key and why would you choose it? [2 marks} Give the validation rules you would use for each field that is to be validated. [4 marks] A teacher wants to know the names of the textbooks available for a history class with 30 students init, ‘Complete the query-by-example grid below to show the search condition required. [3 marks] 4 a Write a query-by-example grid for the search condition in end of chapter question 3b (on page 177 of the textbook); the table name is OILCO. [3 marks] @ Cambridge IGCSE Computer Science Workbook Photocopying prohibited 13 Databases b Write a query-by-example grid for the search condition in end of chapter question 4b; the table name is SHOP. [3 marks] 5a Write a query-by-example grid for the search condition in end of chapter question 3¢; the table name is OILCO. [3 marks] b Write a query-by-example grid for the search con chapter question 4c; the table name is SHOP. [3 marks] Photocopying prohibited ‘Cambridge IGCSE Computer Science Workbook @ Cambridge IGCSE® Computer Science Workbook This workbook supports students using the Cambridge IGCSE Computer Science textbook, providing plenty of extra practice Picea ees Pe eae ee eee ot asd learn each topic thoroughly eeu eae eee eS. CU tle wee eT Ue EU Ree Cee eo ea) eee DU EE CULL Rout For 25 years we have been trusted by Cambridge schools around the world to provide quality support for teaching and learning. For this reason we have been selected by Cambridge International Examinations as an official publisher of endorsed material for their syllabuses. & ROR www.hoddereducation.com

You might also like