Tayyari Karo Open the app

A Level Computer Science 9618 May/June 2023: past paper questions with answers

Practise 104 real questions from the May/June 2023 exam series, from Paper 1, Paper 2, Paper 3, Paper 4. See the answer and explanation as soon as you answer.

104real questions
4papers
10topics

About the May/June 2023 Computer Science paper

May/June 2023 is one of the exam sessions in our A Level Computer Science (Cambridge (CAIE) 9618) question bank. We have 104 real questions from it. Work through them, open the explanation for each one, and redo the ones you missed a few days later.

Try 8 real questions from May/June 2023

These are real past-paper questions. Think of your answer first, then open the explanation.

May/June 2023 · Paper 1 · Databases

(a)(i) An organisation uses a database to store data about bird sightings. State what is meant by a data dictionary and give one example of an item typically found in a data dictionary.

Show model answer

Definition: Data about the data in the database / data about the structure of the database / metadata for a database.
Example: table names, data types, field names.

2 marks: 1 for definition, 1 for example.

May/June 2023 · Paper 1 · Data representation

(d)(ii) Convert the denary number 964 into Binary Coded Decimal (BCD).

Show model answer

1001 0110 0100

1 mark.

May/June 2023 · Paper 1 · Networks and communication

(d)(i) Each device on the network has an IP address. Complete the description.
An IPv4 address contains ___ groups of digits. Each group is represented in ___ bits and the groups are separated by full stops.
An IPv6 address contains ___ groups of digits. Each group is represented in ___ bits. Multiple groups that only contain zeros can be replaced with a ___.

Show model answer

An IPv4 address contains 4 groups of digits. Each group is represented in 8 bits and the groups are separated by full stops.
An IPv6 address contains 8 groups of digits. Each group is represented in 16 bits. Multiple groups that only contain zeros can be replaced with a :: (double colon).

5 marks: 1 for each term.

May/June 2023 · Paper 2 · Programming and object-oriented programming

4 Function Replace() will: take three parameters (a string, an original char, a new char); form a new string where all instances of the original character are replaced by the new character; return the new string. Write pseudocode for function Replace().

Show model answer

FUNCTION Replace(OldString : STRING, Char1, Char2 : CHAR) RETURNS STRING
DECLARE NewString : STRING
DECLARE ThisChar : CHAR
DECLARE Index : INTEGER
NewString ← ""
FOR Index ← 1 TO LENGTH(OldString)
ThisChar ← MID(OldString, Index, 1)
IF ThisChar = Char1 THEN
ThisChar ← Char2
ENDIF
NewString ← NewString & ThisChar
NEXT Index
RETURN NewString
ENDFUNCTION

6 marks: 1 for function heading and ending, 1 for declaration of local variables, 1 for loop for length of OldString, 1 for extract char and test in loop, 1 for concatenate to build NewString in loop, 1 for Return NewString.

May/June 2023 · Paper 2 · Algorithms and software development

(e) Explain why the search in module CheckNewItem() is efficient (the algorithm/search/iteration can stop if the current value read from the file is greater than the value being searched for).

Show model answer

• The algorithm / search / iteration can stop / only iterates
• If the current value read from the file / current line in file
• Is greater than the value being searched for

3 marks: 1 for each marking point.

May/June 2023 · Paper 3 · Data structures and data types

(a) Pseudocode is to be written to implement a queue ADT with items of string data type. FrontPointer (INTEGER) points to start, RearPointer (INTEGER) points to end, Length (INTEGER) is current size, Queue is a 1D array. MaxSize = 60. Write pseudocode to declare MaxSize, FrontPointer, RearPointer, Length and Queue.

Show model answer

CONSTANT MaxSize = 60
DECLARE Queue : ARRAY[1:60] OF STRING
DECLARE FrontPointer : INTEGER
DECLARE RearPointer : INTEGER
DECLARE Length : INTEGER

3 marks: 1 for correctly defined constant, 1 for correctly defined array, 1 for three correctly defined integers.

May/June 2023 · Paper 4 · Programming and object-oriented programming

(d)(i) Amend the main program to: prompt user to input whole number between 0 and 100 inclusive; validate input; call LinearSearch() with DataArray and validated input; output result in format "The number 7 is found 2 times."

Show model answer

Java: System.out.println("Enter a number to find");
Integer DataToFind = -1;
Scanner NewScanner = new Scanner(System.in);
while(DataToFind < 0 || DataToFind > 100) {
DataToFind = Integer.parseInt(NewScanner.nextLine());
}
Integer NumberTimes = LinearSearch(DataArray, DataToFind);
System.out.println("The number " + DataToFind + " is found " + NumberTimes + " times");
Python:
DataToFind = int(input("Enter a number to find "))
while DataToFind < 0 or DataToFind > 100:
DataToFind = int(input("Enter a number to find "))
NumberTimes = LinearSearch(DataArray, DataToFind)
print("The number", DataToFind, "is found", NumberTimes, "times")

4 marks: 1 for prompt and reading input, 1 for validation, 1 for calling LinearSearch and storing return value, 1 for output message.

May/June 2023 · Paper 4 · Programming and object-oriented programming

(d)(i) The main program needs to: instantiate a car as Vehicle with ID "Tiger", MaxSpeed 100, IncreaseAmount 20; instantiate a helicopter with ID "Lion", MaxSpeed 350, IncreaseAmount 40, VerticalChange 3, MaxHeight 100; call IncreaseSpeed() twice for car and output; call IncreaseSpeed() twice for helicopter and output. Write program code for the main program.

Show model answer

Java: Vehicle Car = new Vehicle("Tiger", 100, 20);
Helicopter Heli1 = new Helicopter("Lion", 350, 40, 3, 100);
Car.IncreaseSpeed(); Car.IncreaseSpeed(); Car.OutputCurrentPosition();
Heli1.IncreaseSpeed(); Heli1.IncreaseSpeed(); Heli1.OutputCurrentPosition();

5 marks: 1 for instantiating Vehicle with correct params, 1 for instantiating Helicopter with correct params, 1 for calling IncreaseSpeed twice for car, 1 for calling IncreaseSpeed twice for helicopter, 1 for calling output for both.

Topics in May/June 2023

Questions by paper

PaperQuestions
Paper 129
Paper 223
Paper 326
Paper 426

Common questions

What is in the A Level Computer Science May/June 2023 paper on this page?

104 real A Level Computer Science (9618) questions from the May/June 2023 series, from Paper 1, Paper 2, Paper 3, Paper 4. Each one shows its paper and topic.

Do I get the answers and explanations?

Yes. Every question shows the correct answer and a short explanation the moment you answer.

Can I download the May/June 2023 paper PDF?

Premium includes the paper PDFs. The first papers of each subject are free to open in the app.

Is it free?

You can start free with no signup. Premium unlocks every paper, the full question bank and the paper PDFs.

Other Computer Science exam sessions

All A Level Computer Science questions

Computer Science at other levels

Ready to start?

Free to start. No signup needed to try the questions.

Open Tayyari Karo