GCSE · Computer Science · Eduqas · Spec C500QS
Comparing approaches to requirements
Two programmers each hand you a working solution to the same job. Both give the right answers. Which one do you pick, and how do you prove you picked well?
WHAT YOU'VE LEARNED
A quick recap of today's lesson.
Two programs, one job, both work. How do you decide which one to hand over?
What you need to know
- The same requirements can usually be met by more than one approach, such as different program designs, algorithms or data structures.
- Comparing approaches means listing each one's advantages and disadvantages against the same requirements, so you can justify a choice.
- One point of comparison is how fully the requirements are met. An approach that leaves one unmet, or meets it only partly, is weaker whatever its other strengths.
Have a goYour friend Sam says: "My program is lightning quick. Shame it never prints the average the teacher asked for, but speed beats everything, right?" Is it stronger or weaker than a slower one that prints everything?
Weaker.
An approach that leaves a requirement unmet is weaker whatever its other strengths, so speed cannot cover for a missing output.
- Another is ease of understanding. A clear, simple structure, meaningful identifiers and comments are easier for another programmer to follow than a complex or obscure design.
Have a goWhich would another programmer thank you for: "t = t + m" or "totalScore = totalScore + newMark"?
totalScore = totalScore + newMark
Meaningful identifiers tell the reader what each value is, so the design is easier to follow. The shorter line is not the clearer one.
- Efficiency means fewer processing steps, such as fewer passes through the data or fewer repeated calculations, or less memory or storage for the same result.
- Maintainability means a program split into well-named subroutines or modules, without duplicated code, is easier to correct, change or extend than one long block.
- Trade-offs are common. One approach may be more efficient but harder to understand or maintain, so you weigh each advantage against each disadvantage.
Have a goA program is split into three well-named subroutines, but to get the same answer it goes through the data three times instead of once. Name one advantage and one disadvantage.
Advantage: easier to correct, change or extend. Disadvantage: less efficient, with more passes.
That is a trade-off: it gains on maintainability and gives something up on efficiency, so you weigh the two against the requirements.
- What the requirements need decides how much each point weighs, so the same two approaches can rank differently for different requirements.
- A reasoned comparison makes a point about each approach, explains its effect on how well the requirements are met, then reaches a justified conclusion.
The big picture
The same requirements can usually be met in more than one way. To choose, you compare the approaches on how fully they meet the requirements, how easy they are to understand, how efficient they are and how maintainable they are. Most choices involve a trade-off, so you weigh each advantage against each disadvantage in the light of what the requirements need, then justify a conclusion.
Key points
Worked example
Problem
Two programs both print the 12 times table for a number the user types. Program P has twelve separate print lines, one for each row. Program Q has one loop that prints twelve rows. The school says that next term the table must run to 20 rows. Which program is more suitable? Compare them.
⚠ Watch out
Picking whichever approach looks cleverest, usually the fastest or the shortest, without checking it against the requirements. That ignores unmet requirements and future changes, and it never justifies the choice.
Memory hook
Job, Read, Lean, Grow. Does it do the whole job? Can another person read it? Is it lean on steps? Can it grow later? Then ask what the requirements need most.
Check yourself
Flip the requirements: the same two programs must now process huge amounts of data every night, and nobody will ever edit them. Does your choice change? Which point now matters most, and why?
Flashcards
(10)What does it mean to compare approaches to requirements?
Why can one set of requirements have several correct programs?
Point of comparison: how fully the requirements are met. What does it ask?
Point of comparison: ease of understanding. What makes an approach easier?
Point of comparison: efficiency. What makes an approach more efficient?
Point of comparison: maintainability. What makes an approach easier to maintain?
What is a trade-off between approaches?
An approach leaves one requirement unmet. How does it compare?
What are the three parts of a reasoned comparison?
How do you decide which point of comparison matters most?
Tap any card to flip it, or use Study as deck to go through them one at a time. In the full lesson these run as a spaced-repetition deck — you rate each card Hard, Good or Easy and the tricky ones keep coming back until they stick.
Learning with Lightbulb is opening soon
You can use this lesson now. Join the waitlist and we'll let you know when the full Lightbulb experience is ready.
Keep me postedMore Eduqas GCSE Computer Science topics
- Abstraction
- Analyse a set of requirements
- Authentication management routines
- Consistent programming style
- Creating and extending Python 3 functions/methods
- Creating and extending Python 3 libraries
- Decomposition
- Designing a testing strategy
- Explaining test outcomes
- File handling: open a file
- File handling: read into a variable
- File handling: read into an array
How this lesson was checked. This Eduqas GCSE Computer Science (specification C500QS)lesson was published through Lightbulb Learning's human-designed editorial process — the educational standards, accuracy rules and publication checks it must pass were authored and approved by Philip Halpin. It passed subject-specific assessment, automated educational checks and technical publication verification before going live (publication checks completed 16 November 2026). Published pages are monitored, human spot-checking is ongoing across the lesson library, and anything found wrong is corrected or withdrawn. How our lessons are made and checked. Spotted a mistake? Email hello@lightbulblearning.co and we'll review it.