Free until 14 Nov · 80% off for the first 100 · Pricing

Computer Science 9618/32 May/June 2024: question paper and mark scheme

Cambridge AS & A Level Computer Science (9618), Paper 3 Advanced Theory, May/June 2024. Read both free below, or download them. Done the paper? Get it marked by AI against this mark scheme.

9618_s24_qp_329618_s24_ms_329618/32/M/J/24

Paper
Paper 3 Advanced Theory
Total marks
75
Time
1 hour 30 minutes
Code on the paper
9618/32/M/J/24
9618_s24_ms_32.pdf

9618/32 mark scheme, question by question

Each question as it's printed, and the mark scheme's points for it, as text. Diagrams, tables and graphs are in the PDFs above.

Question 15 marks

Question

(a) Describe the effect of changing the allocation of bits used for the mantissa and for the exponent in a floating-point number with a fixed total number of bits. …… [2] (b) Real numbers are stored in a computer, using floating-point representation with: • 12 bits for the mantissa • 4 bits for the exponent • two’s complement form for both the mantissa and exponent. Calculate the normalised floating-point representation of +54.8125 in this system. Show your working. Mantissa Exponent Working …… …… [3]

Mark scheme

1(a) One mark per mark point (Max 2) 2 MP1 When the number of bits in the mantissa is raised, the precision / accuracy of the number represented increases // when the number of bits in the mantissa is lowered, the precision / accuracy of the number represented reduces. MP2 When the number of bits in the exponent is reduced, the range of numbers that can be represented is reduced // when the number of bits in the exponent is increased, the range of possible numbers that can be represented increases. MP3 When the range increases the accuracy decreases // When the range decreases the accuracy increases. 1(b) One mark per mark point (Max 3) 3 number converted to binary e.g. 54.8125 = 00110110.1101 // Fractions method 1/2 + 1/4 + 1/16 + 1/32 + 1/128 + 1/256 + 1/1024 = 877/1024 // 32 + 16 + 4 + 2 + 0.5 + 0.25 + 0.0625 / (1/2 + 1/4 + 1/16) exponent = 6 // Moving binary point the correct number of places correct answer Mantissa Exponent 0 1 1 0 1 1 0 1 1 0 1 0 0 1 1 0

Question 27 marks

Question

(a) Outline why protocols are essential for communication between computers. …… [2] (b) State the names of two different protocols associated with the sending and receiving of emails between computers. Sending …… Receiving …… [2] (c) Explain the meaning of the phrase: BitTorrent protocol provides peer-to-peer file sharing. …… [3]

Mark scheme

2(a) One mark per mark point (Max 2) 2 MP1 Protocols provide a standard set of rules that enables successful data transfer between devices. MP2 Allows communication between devices on different platforms. MP3 Makes communications independent of software and hardware. 2(b) One mark per mark point 2 MP1 Sending - SMTP MP2 Receiving – POP3 // IMAP // Post Office Protocol 3 2(c) One mark per mark point (Max 3) 3 MP1 BitTorrent allows the sharing of files between thousands of users who are connected together over the internet. MP2 It allows more users to share files with each other than would be the case with a peer-to-peer network. MP3 Users share files directly with each other // the users’ computers are acting as peers MP4 … no web server / central device is used // all users are of equal status.

Question 37 marks

Question

(a) Explain what is meant by the term non-composite data type and give an example of a non-composite data type. Example …… [3] (b) Write pseudocode statements to declare the set data type EvenNumbers to hold this set of even numbers between 2 and 12: 2, 4, 6, 8, 10, 12 …… [4]

Mark scheme

3(a) One mark per mark point (Max 3) 3 MP1 A data type that is defined without referencing another data type. MP2 It can be a primitive data type found in a programming language or a user-defined data type. MP3 Example – enumerated data type / pointer data type / allow a correct example of an enumerated or pointer data type declaration. 3(b) One mark per mark point (Max 4) 4 MP1 Type statement fully correct MP2 DEFINE EvenNumbers MP3 Correct list of values in brackets MP4 : <set identifier> from Type statement used Example answer TYPE Numbers = SET OF INTEGER DEFINE EvenNumbers (2, 4, 6, 8, 10, 12): Numbers

Question 44 marks

Question

Sheila has a customer called Fred. Fred wants to send Sheila a confidential document as part of a transaction. Explain how Fred uses asymmetric encryption to send his document securely. …… [4]

Mark scheme

4 One mark per mark point (Max 4) 4 MP1 Sheila’s computer uses an algorithm to generate a matching pair of keys private and public MP2 Sheila’s computer sends Fred’s computer Sheila’s public key // Fred‘s computer acquires Sheila’s public key MP3 Fred’s computer encrypts the document/plain text using Sheila’s public key to create cipher text MP4 Fred’s computer sends the cipher text to Sheila’s computer The cipher text can only be decrypted using Sheila’s private key // Sheila’s computer uses Sheila’s private key to decrypt the cipher text.

Question 59 marks

Question

(a) Write this infix expression in Reverse Polish Notation (RPN): (7 – 2 + 8) / (9 – 5) …… [2] (b) Evaluate this RPN expression: a d + a b + c - * when a = 6, b = 3, c = 7 and d = 9 Show the changing contents of the stack as the RPN expression is evaluated. [4] (c) Write this RPN expression in infix form: b a c - + d b + * c / …… [3]

Mark scheme

5(a) One mark 7 2 – 8 + 2 One mark 9 5 - / Complete answer 7 2 – 8 + 9 5 - / 5(b) One mark per ring (Max 4) 4 3 7 9 6 6 9 9 2 6 6 15 15 15 15 15 15 30 5(c) One mark per correct term (Max 3) 3 (a – c + b) * (d + b) /c Complete correct answer (((a – c) + b) * (d + b))/c Or (a – c + b) * (d + b)/c

Question 610 marks

Question

The diagram shows a logic circuit. P A S Q B Z T R C (a) Complete the truth table for the given logic circuit. Show your working. Working space A B C P Q R S T Z 0 0 0 0 0 1 0 1 0 0 1 1 1 0 0 1 0 1 1 1 0 1 1 1 [3] (b) Write the Boolean expression that corresponds to the logic circuit as a sum-of-products. Z = …… …… [2] (c) (i) Complete the Karnaugh map (K-map) for this Boolean expression: –– – – – – –– – A.B.C + A.B.C + A.B.C + A.B.C + A.B.C + A.B.C BC A 00 01 11 10 0 1 [2] (ii) Draw loop(s) around appropriate group(s) in the K-map to produce an optimal sum-of-products. [2] (iii) Write the Boolean expression from your answer to part c(ii) as a simplified sum-of-products. …… [1]

Mark scheme

6(a) One mark for working, all five columns P, Q, R, S and T 3 One mark for first four rows of column Z One mark for second four rows of column Z Working space A B C P Q R S T Z 0 0 0 1 1 1 1 1 0 0 0 1 1 1 0 1 0 1 0 1 0 1 0 1 1 0 1 0 1 1 1 0 0 1 0 1 1 0 0 0 1 1 0 0 0 1 0 1 0 1 0 1 0 1 1 1 0 0 0 1 1 0 1 1 1 1 0 0 0 1 0 1 6(b) Two marks for all six correct terms only 2 One mark for any three correct terms (Z = ) A.B.C + A.B.C + A.B.C + A.B.C + A.B.C + A.B.C 6(c)(i) Two marks if all correct 2 One mark if only one error present BC 00 01 11 10 A 0 1 0 1 1 1 1 0 1 1 6(c)(ii) One mark for each correct loop (Max 2) 2 BC 00 01 11 10 A 0 0 1 1 1 1 1 0 1 1 6(c)(iii) B+C 1

Question 76 marks

Question

(a) Outline what is meant by direct access as a method of file access. …… [2] (b) Explain how direct access is used to locate a specific record in sequential files and random files. (i) Sequential files …… …… [2] (ii) Random files …… …… [2]

Mark scheme

7(a) One mark per mark point (Max 2) 2 MP1 Direct access allows a record to be found in a file without other records being read. MP2 Records are found by using the key field of the target record // the location of the record is found using a hashing algorithm. 7(b)(i) One mark per mark point (Max 2) 2 MP1 In sequential files, an index of all key fields is kept MP2 The index is searched for the address of the file location where the target record is stored. 7(b)(ii) One mark per mark point (Max 2) 2 MP1 A hashing algorithm is used on the key field of the record MP2 … to calculate the address of the memory location where the target record is expected to be stored. MP3 Method to find a record if it is not at the expected location e.g. linear probing, search overflow area etc.

Question 88 marks

Question

(a) Complete the pseudocode to find an item in a 1D array Widgets of type STRING, using a linear search. DECLARE Widgets : ARRAY[1:50000] OF STRING DECLARE TopOfList : INTEGER DECLARE EndOfList : INTEGER DECLARE Count : INTEGER DECLARE ToFind : STRING DECLARE Found : BOOLEAN DECLARE NotInList : BOOLEAN TopOfList 1 EndOfList 50000 OUTPUT "Enter the name of the item you wish to find " INPUT ToFind NotInList FALSE Count TopOfList Found TRUE ENDIF Count Count + 1 NotInList TRUE ENDIF ENDWHILE IF Found = TRUE THEN OUTPUT "Item found at position ", Count - 1, " in array" ELSE OUTPUT "Item not in array" ENDIF [4] (b) Compare the methods used by the linear and binary search algorithms to find an item in an array. Refer to Big O notation in your answer. …… [4]

Mark scheme

8(a) One mark for each correctly completed line (Max 4) 4 DECLARE Widgets : ARRAY[1:50000] OF STRING DECLARE TopOfList : INTEGER DECLARE EndOfList : INTEGER DECLARE Count : INTEGER DECLARE ToFind : STRING DECLARE Found : BOOLEAN DECLARE NotInList : BOOLEAN TopOfList ← 1 EndOfList ← 50000 OUTPUT "Enter the name of the item you wish to find " INPUT ToFind Found ← FALSE NotInList ← FALSE Count ← TopOfList WHILE Found = FALSE AND NotInList = FALSE // Count <= EndOfList IF ToFind = Widgets[Count] // Widgets[Count] = ToFind THEN Found ← TRUE ENDIF Count ← Count + 1 IF Found = FALSE AND Count > EndOfList THEN NotInList ← TRUE ENDIF ENDWHILE IF Found = TRUE THEN OUTPUT "Item found at position ", Count - 1, " in array" ELSE OUTPUT "Item not in array" ENDIF 8(b) Max 4 4 One mark per mark point (Max 3) MP1 Linear search sequentially checks each element of the array / list. MP2 … until the matching element is found, or the end of the array / list is reached. MP3 Binary search finds the mid-point of an array/list and determines which side contains the item to be found MP4 … it discards the half of the array/list not containing the search item // … it finds the position of a target value within an array / list by repeatedly halving the target search field. MP5 The binary search requires the elements to be sorted // The linear search does not require the elements to be sorted. MP6 The binary search will usually do many fewer comparisons of records/iterations against the target than a linear search before it finds its target. MP7 Linear search starts at the beginning of the array/list and binary search starts in the middle of the array/list. One mark per mark point (Max 2) MP8 Big O for binary search is O (Log2 n) MP9 Big O for linear search is O (n) MP10 Big O notation is used to indicate the time / space complexity of an algorithm

Question 97 marks

Question

(a) Outline two benefits and two limitations of a virtual machine. Benefit 1 …… Benefit 2 …… Limitation 1 …… Limitation 2 …… [4] (b) Explain the roles of the host operating system and the guest operating system as used in a computer system running a virtual machine. …… [3]

Mark scheme

9(a) One mark per mark point for up to two benefits (Max 2) 4 MP1 COMPATIBILTY e.g. Applications that aren’t compatible with the host computer can be run on the virtual machine // It is possible to emulate old software on a new system by running a compatible guest operating system as a virtual machine // Software can be tried on different OS on the same hardware. MP2 PROTECTION e.g. The guest operating system has no effect on anything outside the virtual machine other virtual machines or the host computer//Virtual machines are useful for testing as they will not crash the host computer if something goes wrong // Easier to recover if software causes a system crash as virtual machine software protects the host system. MP3 COST e.g. No need to buy extra computers / hardware as multiple virtual machines can be implemented on the same hardware. One mark per mark point for up to two limitations (Max 2) MP4 PERFORMANCE e.g. The performance of the guest operating system will not be as good on a virtual machine as it would be on its own compatible machine because of the extra code / using more RAM/memory space // The performance of the VM is dependent on the capabilities of the host computer // Response times cannot be accurately measured using a virtual machine. MP5 COMPLEXITY e.g. Building an in-house virtual machine can be expensive, time consuming and complex to maintain / set-up. MP6 HARDWARE/SOFTWARE ISSUES e.g. Some hardware/software can’t be emulated with a virtual machine // Some of the host machine’s hardware can’t be directly accessed by the virtual machine. 9(b) One mark per mark point – host operating system (Max 2) 3 MP1 The host operating system is the normal operating system for the host computer / machine. MP2 It has control of all the resources of the host computer / machine. // It can access the physical resources of the host computer / machine. MP3 It provides a user interface to operate the virtual machine software. MP4 It also runs the virtual machine software. One mark per mark point – guest operating system (Max 2) MP5 The guest operating system runs within the virtual machine. MP6 … it controls the virtual hardware/software during the emulation. // It accesses the actual hardware through the virtual machine and host operating system. MP7 It provides a virtual user interface for the emulated hardware/software. MP8 The guest operating system runs under the control of the host operating system.

Question 109 marks

Question

A declarative programming language is used to allow clients to choose daily activities at the beach. 01 activity(paddleboarding). 02 activity(sailing). 03 activity(rowing). 04 activity(kayaking). 05 activity(jetskiing). 06 client(stevie). 07 client(antonio). 08 client(henry). 09 client(eliza). 10 client(rebeka). 11 client(danny). 12 client(erik). 13 client(simone). 14 client(petra). 15 client(frankie). 16 choice(petra, rowing). 17 choice(frankie, sailing). 18 choice(erik, sailing). 19 choice(eliza, rowing). 20 choice(stevie, jetskiing). 21 choice(henry, sailing). 22 done(henry, jetskiing). 23 done(rebeka, jetskiing). 24 done(antonio, kayaking). These clauses have the meanings: Clause Meaning 01 Paddle boarding is an activity. 06 Stevie is a client. 16 Petra has chosen rowing. 22 Henry has already done jet skiing. (a) Jane is a client who would like to choose the activity surfing and she has already done sailing. Write additional clauses to represent this information. 25 …… 26 …… 27 …… 28 …… [4] (b) Using the variable List, the goal: choice(List, rowing) returns List = petra, eliza Write the result returned by the goal: choice(List, sailing) List = …… [1] (c) C is a client who would like to choose A if A is an activity and C has not already done A. Write this as a rule: may_choose_activity(C, A) IF …… …… [4]

Mark scheme

10(a) One mark for each correctly completed clause (Max 4) 4 Example answer (25) client(jane). (26) activity(surfing). (27) choice(jane, surfing). (28) done(jane, sailing). 10(b) (List =) frankie, erik, henry 1 10(c) One mark per mark point (Max 4) 4 MP1 client(C) MP2 activity(A) MP3 done(C, A) MP4 all correct Boolean operators and punctuation (allow , for AND). There must be the correct number of terms and no additional lines of code Example answers may_choose_activity(C, A) IF client(C) AND activity(A) AND NOT done(C, A). client(C), activity(A), NOT (done(C, A)).

Question 113 marks

Question

Explain what is meant by Reinforcement Learning in relation to Artificial Intelligence. …… [3]

Mark scheme

11 One mark per mark point (Max 3) 3 MP1 Reinforcement learning is a machine learning technique based on feedback / rewards / punishment. MP2 … in which an agent learns to behave in an environment by performing the actions and seeing the results of the actions. MP3 … for each good action, the agent gets positive feedback / reward and each bad action receives negative feedback / punishment. MP4 The agent learns automatically using feedback without any labelled data / specific instructions. MP5 Adjust node weightings to achieve the correct outcome. // Using feedback to improve its performance at accomplishing similar tasks.

Checked your answers against these? Let AI mark the whole paper, on your own working.

Mark my 9618/32

How this paper is marked

Examiners follow the generic marking principles at the front of the scheme, then each question's points: method (M), accuracy (A) and independent (B) marks, error carried forward where the scheme allows it, and positive marking, so you're credited for what you got right.

Check your answers against it

Done this paper? Upload your script and CIE Buddy's AI marker marks it question by question against this exact scheme, puts the ticks on your own working and says what each lost mark needed.

9618/32 in other series

Find another Computer Science paper

Every AS & A Level Computer Science mark scheme

Question papers and mark schemes © Cambridge University Press & Assessment. CIE Buddy is independent and not connected to Cambridge.

9618/32 questions

Where can I find the 9618/32 May/June 2024 mark scheme?

On this page, free: the mark scheme for AS & A Level Computer Science 9618/32, May/June 2024 (9618_s24_ms_32), and the question paper (9618_s24_qp_32), to read or download, with each question's marking points written out underneath.

How many marks is 9618/32 out of?

Computer Science 9618/32 for May/June 2024 is out of 75 marks, with 1 hour 30 minutes to answer it.

Can I get my 9618/32 answers marked?

Yes. Upload your answers to 9618/32/M/J/24 as a PDF or photos, and CIE Buddy marks every question against this paper's official mark scheme, using Cambridge's marking rules. You get your score, each lost mark explained on your own script, and the topics to revise. It's a guide, not an official Cambridge grade.