How to answer a 15-mark scenario question in IGCSE Computer Science

Learn a repeatable method for tackling the long scenario-based pseudocode question in Cambridge IGCSE Computer Science Paper 21. You will plan the answer, break the scenario into requirements, and write clear pseudocode that earns AO2 and AO3 marks. It suits students sitting the 0478 exams who already know basic programming.

IGCSE | O Level Computer Science - The Scenario-based Question-15 Marks May/June 2026 Paper 21, by Learn CS with SY on YouTube. 22 min 24 s.

5 chapters. Tap a step to jump to it.Chapters from the creator
Video length
22 min 24 s
Time to do it
25 minutes
Difficulty
Medium
Steps
10

What you need

Steps

  1. Read the whole scenario once without writing anything. Underline the inputs, the processes and the outputs the question asks for.

  2. List the requirements as short bullet points. Note the exact identifiers the question tells you to use, such as sunshine and month_days.

  3. Plan the structure before writing code: input section, validation, processing loop, then output. Keep the order logical.

  4. Declare your arrays and variables with meaningful names. Use the identifiers from the question exactly as given.

  5. Handle the leap year first. Use MOD to check if the year divides by 4, then set February to 29 days in the month_days array.

  6. Ask the user for a month and use a CASE statement to pick the matching number of days from month_days.

  7. Validate each daily sunshine value with REPEAT UNTIL so it sits between 1 and 1440 minutes before you accept it.

  8. Loop through every day of the chosen month. Add each value to a running total and update a maximum variable when a value is higher.

  9. Convert the total minutes into hours and minutes using DIV and MOD, then output the year, month, total sunshine and highest daily sunshine.

  10. Add short comments and check your indentation. Reread the question to confirm every requirement is covered.

Tips and common mistakes

Underline the command words and identifiers before you write any code, so you do not lose easy marks.

Use meaningful variable names and comments, as the mark scheme rewards maintainable code.

Do not skip input validation, because the REPEAT UNTIL loop is usually worth several marks.

Leave a few minutes to trace your pseudocode with a sample month and check the output is correct.

Questions

How many marks is the scenario-based question worth?

In this lesson it is a 15-mark question, so it carries a large share of the paper. Plan a few minutes before writing to cover all the requirements.

Do I need to write real code?

No. Cambridge expects pseudocode that follows their conventions, with clear structure, indentation and comments.

What if I forget the leap year rule?

A year is a leap year when it divides by 4 with no remainder, which you test with MOD. Then February has 29 days instead of 28.

This guide was drafted from the video's details and general task knowledge. It has not been checked against the full video. Check the video and relevant product instructions before following a procedure. Report a correction.

More in School & Learning

See all