9618/22

Computer Science 9618/22October/November 2023

Cambridge AS Level · Fundamental Problem-solving and Programming Skills · worked solutions for every part, with the mark scheme

8
questions
75
marks
120
minutes

Topics Programming · Data Types and Structures · Algorithm Design and Problem-solving · Software Development

Q1Data Types and StructuresProgrammingFree sample

Refer to the insert for the list of pseudocode functions and operators.

A shop sells car accessories. A customer order is created if an item cannot be supplied from current stock. A program is being developed to create and manage the customer orders.

(a)

The following identifier table shows some of the data that will be stored for each order.

Complete the identifier table by adding meaningful variable names and appropriate data types.

Example valueExplanationVariable nameData type
"Mr Khan"The name of the customer
3The number of items in the order
TRUETo indicate whether this is a new customer
15.75The deposit paid by the customer
4M
(b)

Other variables in the program have example values as shown:

VariableExample value
Total124.00
DepRate2.00
Description"AB12345:Cleaning Brush (small)"

Complete the table by evaluating each expression using the example values.

ExpressionEvaluates to
(Total * DepRate) + 1.5
RIGHT(Description, 7)
(LENGTH(Description) - 8) > 16
NUM_TO_STR(INT(DepRate * 10)) & '%'
4M
(c)

The data that needs to be stored for each customer order in part (a) is not all of the same type.

Describe an effective way of storing this data for many customer orders while the program is running.

...................................................................................................................................................

...................................................................................................................................................

...................................................................................................................................................

...................................................................................................................................................

...................................................................................................................................................

.............................................................................................................................................

3M

The rest of this paper

7 more questions
  • Q2Algorithm Design and Problem-solving · Programming7M
  • Q3Data Types and Structures9M
  • Q4Algorithm Design and Problem-solving · Programming · Software Development9M
  • Q5Data Types and Structures · Programming6M
  • Q6Data Types and Structures · Programming9M
  • Q7Software Development · Programming6M
  • Q8Programming · Data Types and Structures18M
Loading the full paper…