AQA GCSE COMPUTER SCIENCE Paper 1 Computational thinking and programming skills – Python M, Exams of Computer Science

AQA GCSE COMPUTER SCIENCE Paper 1 Computational thinking and programming skills – Python MAY 2024 Merged QP AND MS

Typology: Exams

2024/2025

Available from 06/05/2025

LectVictor
LectVictor 🇺🇸

3

(3)

16K documents

1 / 91

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Please write clearly in block capitals.
Centre number
Candidate number
Surname
Forename(s)
Candidate signature
I declare this is my own work.
For the multiple-choice questions, completely fill in the lozenge alongside the appropriate answer.
WRONG
METHODS
If you want to change your answer you must cross out your original answer as shown.
If you wish to return to an answer previously crossed out, ring the answer you now wish to select as
shown.
AQA GCSE COMPUTER SCIENCE Paper 1 Computational thinking and programming skills
Python MAY 2024 Merged QP AND MS
GCSE
COMPUTER SCIENCE
Paper 1 Computational thinking and programming skills Python
Wednesday 15 May 2024 Afternoon
Time allowed: 2 hours
Materials
There are no additional materials required for this paper.
You must not use a calculator.
Instructions
Use black ink or black ball-point pen. Use pencil only for drawing.
Answer all questions.
You must answer the questions in the spaces provided.
If you need extra space for your answer(s), use the lined pages at the end of
this book. Write the question number against your answer(s).
Do all rough work in this book. Cross through any work you do not want
to be marked.
Questions that require a coded solution must be answered in Python.
You should assume that all indexing in code starts at 0 unless stated otherwise.
Information
The total number of marks available for this paper is 90.
Advice
For Examiner’s Use
Question
Mark
1
23
45
67
89
1011
12
1314
15
TOTAL
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18
pf19
pf1a
pf1b
pf1c
pf1d
pf1e
pf1f
pf20
pf21
pf22
pf23
pf24
pf25
pf26
pf27
pf28
pf29
pf2a
pf2b
pf2c
pf2d
pf2e
pf2f
pf30
pf31
pf32
pf33
pf34
pf35
pf36
pf37
pf38
pf39
pf3a
pf3b
pf3c
pf3d
pf3e
pf3f
pf40
pf41
pf42
pf43
pf44
pf45
pf46
pf47
pf48
pf49
pf4a
pf4b
pf4c
pf4d
pf4e
pf4f
pf50
pf51
pf52
pf53
pf54
pf55
pf56
pf57
pf58
pf59
pf5a
pf5b

Partial preview of the text

Download AQA GCSE COMPUTER SCIENCE Paper 1 Computational thinking and programming skills – Python M and more Exams Computer Science in PDF only on Docsity!

Please write clearly in block capitals. Centre number Candidate number Surname Forename(s) Candidate signature I declare this is my own work. For the multiple-choice questions, completely fill in the lozenge alongside the appropriate answer. CORRECT METHOD WRONG METHODS If you want to change your answer you must cross out your original answer as shown. If you wish to return to an answer previously crossed out, ring the answer you now wish to select as shown.

AQA GCSE COMPUTER SCIENCE Paper 1 Computational thinking and programming skills –

Python MAY 2024 Merged QP AND MS

GCSE

COMPUTER SCIENCE

Paper 1 Computational thinking and programming skills – Python

Wednesday 15 May 2024 Afternoon Time allowed: 2 hours Materials

  • There are no additional materials required for this paper.
  • You must not use a calculator. Instructions
  • Use black ink or black ball-point pen. Use pencil only for drawing.
  • Answer all questions.
  • You must answer the questions in the spaces provided.
  • If you need extra space for your answer(s), use the lined pages at the end of this book. Write the question number against your answer(s).
  • Do all rough work in this book. Cross through any work you do not want to be marked.
  • Questions that require a coded solution must be answered in Python.
  • You should assume that all indexing in code starts at 0 unless stated otherwise. Information The total number of marks available for this paper is 90. Advice For Examiner’s Use Question Mark 1 2 – 3 4 – 5 6 – 7 8 – 9 10 – 11 12 13 – 14 15 TOTAL

JUN24 5251 01 IB/G/Jun24/G4005/E11 8525/1B

Do not write outside the 03

. Which of the following would be the most suitable data type for the variable year?

Shade one lozenge. box [1 mark] A Boolean B character C integer D real

. Describe what is meant by an assignment statement in a program. [1 mark] Question 1 continues on the next page Turn over ►

Do not write outside the 04

. 5 Write a Python program that: - gets the user to enter the name of a film - displays You entered followed by the name of the film entered by the user. The output from the program must be on one line. You should use indentation as appropriate, meaningful variable name(s) and Python syntax in your answer. box The answer grid below contains vertical lines to help you indent your code accurately. [2 marks] 6

Do not write outside the 06

Figure 2 shows an algorithm, represented using pseudo-code.

  • Line numbers are included but are not part of the algorithm. Figure 2

1 num  USERINPUT

2 IF NOT(num > 1) OR num > 20 THEN

3 OUTPUT "False"

4 ELSEIF num > 1 AND num < 15 THEN

5 OUTPUT "Almost"

6 ELSEIF num MOD 5 = 0 THEN

7 OUTPUT "True"

8 ELSE

9 OUTPUT "Unknown"

10 ENDIF

The modulus operator is used to calculate the remainder after dividing one integer by another. For example:

  • 14 MOD 3 evaluates to 2
  • 24 MOD 5 evaluates to 4 box . (^) Where is a relational operator first used in the algorithm in Figure 2? Shade one lozenge. [1 mark] A Line number 1 B Line number 2 C Line number 3 D Line number 6

Do not write outside the 2 3 4 5

. In the algorithm in Figure 2 , what will be the output when the user input is 5?

Shade one lozenge. [1 mark] box

A Almost

B False

C True

D Unknown

. Which value input by the user would result in True being output by the algorithm in

Figure 2? Shade one lozenge. [1 mark]

A -^1

B 10

C 20

D^21

. Rewrite line 2 from the algorithm in Figure 2 without using the NOT operator.

The algorithm must still have the same functionality. [1 mark]

. A user inputs a value into the algorithm in Figure 2.

State one value that the user could input that would result in an output of Unknown

[1 mark] Turn over ► 07

Do not write outside the 09

. Complete the test plan in Table 1 to test the validation of userNumber in the

program in Figure 3. box [2 marks] Table 1 Test number Test type Test data Expected result

1 Erroneous 150

2 Boundary

3 Normal Valid number entered

. In an earlier version of the program in Figure 3 , line 5 contained one syntax error and one logic error:

whil userNumber < 1 or userNumber >= 100:

Complete the table to describe the errors in the program on line 5. [2 marks] Turn over ►

Error type (^) Description Syntax error Logic error

Do not write outside the

  • 10 *

. (^) Define the term abstraction. [1 mark] box . State the name for the process of breaking a problem down into sub-problems. [1 mark]

Do not write outside the

  • 12 * A university is writing a program to calculate a student’s total mark for three essays. If any essays are handed in late, the total mark is reduced. Write a Python program to calculate the total mark.

You should assume there are three integer variables called e1, e2 and e3 which

have already been given values to represent the marks of the three essays. The program should:

  • get the user to enter the number of essays handed in late and store the number in a variable
  • calculate the total mark for the three essays o if only one essay is handed in late, the total mark is reduced by 10 o if more than one essay is handed in late, the total mark should be halved o the total mark should not be less than 0
  • output the total mark. You should use indentation as appropriate, meaningful variable name(s) and Python syntax in your answer. box The answer grid below contains vertical lines to help you indent your code. [7 marks]

Do not write outside the

  • 13 * Turn over for the next question box Turn over ►

Do not write outside the

  • 15 *

Turn over for the next question box Turn over ►

Do not write outside the

  • 16 * Figure 6 shows an algorithm, represented using pseudo-code. box Figure 6

days  [10, 15, 4]

sales  [20, 33, 12]

weeks  [0, 0, 0]

FOR i  0 TO 2

daysTotal  days[i] + sales[i]

weeks[i]  daysTotal DIV 7

ENDFOR

weeksTotal  weeks[0] + weeks[1] + weeks[2]

OUTPUT weeksTotal

The DIV operator is used for integer division.

Complete the trace table for the algorithm in Figure 6. Part of the table has already been filled in. You may not need to use all the rows in the table. [6 marks]

i daysTotal

weeks

weeksTotal

[0] [1] [2]

Do not write outside the

. 2 Figure 7 shows an incomplete algorithm, represented using pseudo-code. The algorithm is used to store and manage books using records. The algorithm should do the following: - create a record definition called Book with the fields bookName, author and

price

  • create a variable for each book using the record definition. box Complete Figure 7 by filling in the gaps using the items in Table 2.
  • You may need to use some of the items in Table 2 more than once.
  • You will not need to use all the items in Table 2. Table 2

1 2 author

B1 B2 Book

bookName i Real

OUTPUT String Boolean

Figure 7

RECORD

[3 marks]

bookName : String

: String

price :

ENDRECORD

B1  Book("The Book Thief", "M Zusak", 9.99)

B2  ("Divergent", "V Roth", 6.55)

*1 *

Do not write outside the

  • 19 *

. 3 Write an algorithm using pseudo-code to display the name of the most expensive book. box The algorithm should:

  • compare the price of B1 and the price of B
  • output the book name of the most expensive book
  • output Neither if the books are the same price.

The algorithm should work for any values stored in B1 and B

[3 marks] Turn over for the next question Turn over ►