Designing, creating and refining algorithms: OCR GCSE Computer Science questions
Every OCR GCSE Computer Science exam question on 2.1.2 Designing, creating and refining algorithms, 2022–2025, with its mark scheme and examiner’s report.
Paper
All papers
Exam
All years
Calculations
Q2(a)
The whole paper ↗Q6(d)(i)
The whole paper ↗Q6(d)(ii)
The whole paper ↗Q6(e)
The whole paper ↗Q3(b)
The whole paper ↗Q4(a)
The whole paper ↗Q9(b)
The whole paper ↗Q9(f)
The whole paper ↗Q1(d)
The whole paper ↗Q2(b)
The whole paper ↗Q5(c)
The whole paper ↗Q2(b)
The whole paper ↗Q2(c)
The whole paper ↗Q2(d)(ii)
The whole paper ↗Q4(c)
The whole paper ↗Q5(d)
The whole paper ↗Q5(e)
The whole paper ↗Q2(a)
The whole paper ↗Q2(b)
The whole paper ↗
All 26 questions on Designing, creating and refining algorithms, as a list
- June 2025, Paper 2, Q2(a) (2 marks): Complete the table by identifying how many times "OK" will be output for when each value is input. Input value Number of times "OK" is output 3 10 [2]
- June 2025, Paper 2, Q6(d)(i) (4 marks): Complete the trace table for the algorithm. You may not need to use all rows in the table. count x Line number Output [4]
- June 2025, Paper 2, Q6(d)(ii) (2 marks): The array actNumbers is changed to include data for two more stages. The new array is shown: 0 1 2 3 4 Index 10 14 6 9 11 Data actNumbers The algorithm from par
- June 2025, Paper 2, Q6(e) (6 marks): There are 500 tickets available for the music festival. The number of tickets currently available is stored in the variable tickets Complete the algorithm to: •
- June 2024, Paper 2, Q2 (4 marks): An algorithm decides if a number is odd or even. An odd number divided by 2 will give the remainder 1. The flowchart statements have been written for the algori
- June 2024, Paper 2, Q3(b) (4 marks): A student writes an algorithm to input two numbers and add them together to create a total. If the total is between 10 and 20 inclusive, "success" is output. If
- June 2024, Paper 2, Q4(a) (2 marks): Identify one input and one output for the program. Input Output [2]
- June 2024, Paper 2, Q9(b) (4 marks): This algorithm calculates the number of points a student gets for the distance they throw in the javelin: 01 javelinThrow = input("Enter distance") 02 yearGroup
- June 2024, Paper 2, Q9(f) (6 marks): An algorithm works out which team has won (has the highest score). Write an algorithm to: • prompt the user to enter a team name and score, or to enter "stop" t
- June 2023, Paper 2, Q1(d) (3 marks): Read the following pseudocode algorithm: 01 start = 3 02 do 03 print(start) 04 start = start - 1 05 until start == -1 06 print("Finished") Complete the followin
- June 2023, Paper 2, Q2(b) (4 marks): Identify two logic errors in the pseudocode algorithm. Write the refined line to correct each error. Error 1 line number Corrected line Error 2 line number Corr
- June 2023, Paper 2, Q5(c) (6 marks): Write an algorithm to play this game. The rules are repeated from the start of the question here: • the player is asked 3 addition questions • each question ask
- June 2022, Paper 2, Q2(b) (5 marks): The restaurant needs an algorithm designing to help employees work out if a customer can have a half price meal or not. It should: • input required data • decid
- June 2022, Paper 2, Q2(c) (2 marks): The restaurant adds a service charge to the cost of a meal depending on the number of people at a table. If there are more than five people 5% is added to the t
- June 2022, Paper 2, Q2(d)(ii) (4 marks): Complete the following trace table for the given algorithm when the surname “Kofi” and the year 2021 are entered. You may not need to use all rows in the table.
- June 2022, Paper 2, Q4(c) (6 marks): Jack decides to improve his program. He wants to be able to input how many numbers to add together each time the algorithm runs, and also wants it to calculate
- June 2022, Paper 2, Q5(d) (2 marks): The hotel has nine rooms that are numbered from room 0 to room 8. The number of people currently staying in each room is stored in an array with the identifier
- June 2022, Paper 2, Q5(e) (6 marks): The hotel car park charges £4 per hour. If the car is electric, this price is halved to £2 per hour. Write an algorithm to: • take as input the number of hours
- Specimen, Paper 2, Q2(a) (5 marks): Complete the pseudocode for this program. num1 = ……………………………………………… num2 = input("enter second number") ……………………… num1 > ……………………… then ……………………………………………… else
- Specimen, Paper 2, Q2(b) (5 marks): A second program needs to perform the following tasks: • Input a number from the user • Double the number input and print the result • Repeat bullets 1 and 2 un
- Specimen, Paper 2, Q4(a) (1 mark): State, using the process in Fig. 2, the username for Rebecca Ellis. ……………………………………………………………………………………………………………. [1]
- Specimen, Paper 2, Q4(b)(i) (1 mark): What would be the username for a teacher called Fred Biscuit using the updated process? ……………………………………………………………………………….……………………... [1]
- Specimen, Paper 2, Q4(b)(ii) (6 marks): Write an algorithm for the updated program design shown in question 4(b)(i). ……………………………………………………………………………………………..…………… ……………………………………………………………………………………………..………
- Specimen, Paper 2, Q8(e) (4 marks): The following program uses a condition-controlled loop. x = 15 y = 0 while x > 0 y = y + 1 x = x – y endwhile print(y) Complete the trace table to test this pro
- Specimen, Paper 2, Q8(g)(i) (2 marks): Identify the input and output required from this algorithm. Input …….……………………………………………………………………………………………… ……...…………………………………………………………………………………………………… Output …..
- Specimen, Paper 2, Q8(g)(iii) (4 marks): The following flowchart outputs a message depending on how long each person has spent playing computer games. START END Rewrite the flowchart as a program. You
Questions, mark schemes and examiner’s reports are © OCR, from their published past papers. Plumi isn’t affiliated with any exam board. Want whole papers? Full past papers.
Rather write your answers by hand on iPad? Plumi marks them against the same mark schemes.