Programming — IGCSE Computer Science (0478) questions by topic
Programming questions give candidates flawed pseudocode or flowcharts, such as a WHILE loop condition that never triggers, and ask them to identify errors, explain corrections, or convert a loop structure to count-controlled. Identify, complete, write, explain and describe are the command words, with explain wanting the fix described in words alongside, where needed, a short snippet of corrected code.
11 real questions from 2023 to 2025 papers make up this page, worth 8 to 12 marks. Because a single wrong Boolean operator or loop bound can break an entire algorithm, submitting your corrected pseudocode for instant marking is the fastest way to check whether a fix actually solves the stated problem rather than introducing a new one.
What examiners look for
- Most candidates found this type of question challenging, according to the reports, and a recurring mistake was using program code instead of the description the question asked for.
- Examiners also flag only rewriting the algorithm rather than correcting it, indicating the wrong Boolean operator for a specific line, and not using correct flowchart symbols or arrows that touch the symbols they connect.
- Strong answers identified and corrected at least one error, with some candidates achieving high marks describing the conversion to a count-controlled loop.
- Reports praise candidates who provided all four errors and corrections, describing each change with a description and a snippet of code.
May–June 2025, Paper 22
The flowchart shows an algorithm that is used to input 50 numbers. Each number is stored in the variable Value when it is input. Any number input that is less than or equal to −20…
Answer this question and get it marked →May–June 2024, Paper 21
This pseudocode algorithm is intended to allow, at random, between 1 and 20 values to be entered and totalled. The total and average of the entered values are output at the end.…
Answer this question and get it marked →May–June 2024, Paper 23
This pseudocode algorithm is intended to allow data for up to 50 people to be entered and stored in a 2D array. The data is their last name, first name and the city in which they…
Answer this question and get it marked →October–November 2024, Paper 21
An incomplete algorithm has been written in pseudocode to count the number of zeros stored in an array and total the non-zero values. 01 DECLARE A[1:50] : INTEGER 02 DECLARE C :…
Answer this question and get it marked →An algorithm has been written in pseudocode to check if a temperature is in a given range. The temperature values used in the algorithm are correct. 01 REPEAT 02 OUTPUT "Please…
Answer this question and get it marked →October–November 2024, Paper 22
This pseudocode algorithm is intended to sort a pre-populated 1D array named ItemList into alphabetical order using a bubble sort. 01 DECLARE ItemList : ARRAY[1:100] OF STRING 02…
Answer this question and get it marked →October–November 2024, Paper 23
An incomplete algorithm has been written in pseudocode to count the number of values stored in an array and to find their average. Values have been stored in the array starting at…
Answer this question and get it marked →May–June 2023, Paper 21
An algorithm has been written in pseudocode to allow some numbers to be input. All the positive numbers that are input are totalled and this total is output at the end. An input…
Answer this question and get it marked →May–June 2023, Paper 23
An algorithm has been written in pseudocode to allow 100 positive numbers to be input. The total and the average of the numbers are output. 01 Counter ← 100 02 Total ← 0 03 WHILE…
Answer this question and get it marked →October–November 2023, Paper 22
An algorithm has been written in pseudocode to allow the names of 50 cities and their countries to be entered and stored in a 2D array. The contents of the array are then output.…
Answer this question and get it marked →October–November 2023, Paper 23
An algorithm has been written in pseudocode to check if a new password is in a list of previously used passwords OldList[]. If the password is not found, the new password will be…
Answer this question and get it marked →Other IGCSE Computer Science topics
- Hardware (108)
- Algorithm design and problem-solving (43)
- Data representation (26)
- The internet and its uses (23)
- Data transmission (21)
- Boolean logic (19)
- Databases (16)
- Automated and emerging technologies (13)
- Software (12)