CIE IGCSE | TOPIC 7 ASSESSMENT
ALGORITHM DESIGN AND PROBLEM-SOLVING: END OF TOPIC REVIEW
Assess your understanding of development, algorithm design, standard algorithms, data checks, testing, traces and complete scenario solutions. Work independently before revealing feedback.
BEFORE YOU BEGIN
Suggested time: 60–80 minutes, or split into two sessions. Complete sections A and B without notes. Write section C answers in your exercise book before revealing the marking guidance.
Sections A and B provide an automatic score out of 24, one point for each fully correct item. Section C has 34 suggested written marks, assessed separately. These are original practice questions, not an official Cambridge paper or grade boundary.
Use pseudocode and trace tables in your book for the applied tasks. State assumptions and show working where a question requires it. Your answers remain only while this page is open.
C | EXAM-STYLE WRITING
Write in your exercise book before revealing the guidance. Section C assesses subject knowledge and gives you practice expressing it clearly. The first table reproduces the command-word meanings supplied from the Cambridge syllabus. The second gives practical writing guidance for this review.
| CIE command word | Meaning from the specification |
|---|---|
| Calculate | work out from given facts, figures or information |
| Compare | identify/comment on similarities and/or differences |
| Define | give precise meaning |
| Demonstrate | show how or give an example |
| Describe | state the points of a topic / give characteristics and main features |
| Evaluate | judge or calculate the quality, importance, amount, or value of something |
| Explain | set out purposes or reasons / make the relationships between things clear / say why and/or how and support with relevant evidence |
| Give | produce an answer from a given source or recall/memory |
| Identify | name/select/recognise |
| Outline | set out the main points |
| Show (that) | provide structured evidence that leads to a given result |
| State | express in clear terms |
| Suggest | apply knowledge and understanding to situations where there are a range of valid responses in order to make proposals / put forward considerations |
The command applies to the subject context. A brief identification does not need an essay; an explanation needs accurate links. Use the guidance below for the commands in this written review.
| Command word | What your answer should do | Useful writing pattern |
|---|---|---|
| Describe | State the main features or relevant points; for a process, make the sequence clear. | First… Next… Finally… |
| Explain | Give reasons, purposes or clear relationships, supported by relevant subject knowledge. | …because…; therefore…; resulting in…; leading to… |
| Compare | Identify similarities and/or differences, addressing both things on the same basis. | Both…; whereas…; unlike… |
| Evaluate | Make a reasoned judgement about suitability or value in the given context. | A benefit is…; however…; therefore, for this purpose… |
| Calculate | Work out a result using the supplied data. | Show the relevant values and arithmetic. |
| Show (that) | Provide structured evidence leading to the stated result. | Trace intermediate states, then link them to the result. |
| Suggest | Apply knowledge to propose a valid solution or test. | State a proposal and relate it to the requirement. |
BUILD A CLEAR EXPLANATION
Point → reason or mechanism → consequence. Connectives help show the relationship, but the technical link must be accurate. Adding “because” to an unsupported claim does not make it a good explanation.
Thin answer: “The count changes.”
Developed answer: “The count increases by one only after an input is accepted because rejected attempts must not represent extra classes, therefore invalid retries do not inflate the final count.”
Use because or because of to introduce a cause; therefore, resulting in or leading to to show a consequence. For comparison, use both and whereas. For evaluation, use however and finish with a justified judgement.
Write enough relevant detail for the marks available. Clear, concise sentences are better than padding. These are writing supports, not compulsory phrases or separate official language marks.
25 | REQUIREMENTS AND DECOMPOSITION
[4 suggested marks]
A school needs a club-booking system that accepts a student ID, rejects duplicate bookings and rejects bookings when the club is full. Describe two checkable requirements and explain how decomposition helps design this solution.
Sample answer: A request using an already-booked student ID must be rejected without adding another booking. A request made when capacity is reached must also be rejected without increasing the booking count. Decomposition separates receiving a request, checking duplication and capacity, and recording an accepted booking. Therefore each smaller task can be designed and tested while keeping its connection to the overall booking process clear.
- Precise duplicate-rejection requirement: one mark.
- Precise capacity-rejection requirement: one mark.
- Relevant breakdown into component jobs: one mark.
- Explain how smaller jobs support manageable design/testing: one mark.
Writing focus: describe observable behaviour, then connect the decomposition to its benefit.
26 | VALIDATION AND VERIFICATION
[4 suggested marks]
A paper register shows a mark of 34. A user enters 43 into a field permitting whole-number marks from 0 to 50. Compare validation and verification in this context, and explain why both can be useful.
Sample answer: Validation checks whether the entered mark satisfies the specified rules, whereas verification checks whether it was copied accurately from the paper register. Forty-three passes the whole-number range rule but differs from thirty-four, so visual verification should reveal the copying error. Both are useful because a value can be within permitted limits yet inaccurately copied; conversely, accurately copying an invalid source value does not make it valid.
- Rule-based validation contrasted with accurate-copying verification: one mark.
- Apply validation correctly to 43: one mark.
- Apply verification correctly against source 34: one mark.
- Explain complementary roles with a valid link or example: one mark.
Writing focus: address both checks on the same basis, using whereas and because where helpful.
27 | BUBBLE SORT EVIDENCE
[4 suggested marks]
Show (that) a complete first left-to-right ascending bubble-sort pass over [5, 2, 4, 1] produces [2, 4, 1, 5]. Show each adjacent comparison and resulting list. Then explain why this does not establish that sorting is complete.
Sample answer: Compare five and two: swap, giving [2, 5, 4, 1]. Compare five and four: swap, giving [2, 4, 5, 1]. Compare five and one: swap, giving [2, 4, 1, 5]. The largest value has reached the end, but four still precedes one, so an out-of-order pair remains and further passes are needed.
- First comparison and resulting list: one mark.
- Second comparison and resulting list: one mark.
- Third comparison and resulting list: one mark.
- Explain remaining disorder and need for further passes: one mark.
Writing focus: provide structured intermediate evidence rather than only the final list.
28 | TRACE A CONDITIONAL MEAN
[4 suggested marks]
Assume suitable declarations and valid numeric input. Calculate the final Total, Count and output for inputs 2, -1, 4. Show a trace after each outer iteration.
Total ← 0
Count ← 0
FOR Index ← 1 TO 3
INPUT Value
IF Value > 0
THEN
Total ← Total + Value
Count ← Count + 1
ENDIF
NEXT Index
IF Count > 0
THEN
OUTPUT Total / Count
ELSE
OUTPUT "No positive values"
ENDIFSample answer: After input two: Total two, Count one. After minus one: Total two, Count one because the condition is false. After four: Total six, Count two. Count is positive, so the output is six divided by two, or three.
- State after first iteration: one mark.
- Unchanged state after negative input: one mark.
- Final Total six and Count two: one mark.
- Correct final branch and output three: one mark.
Writing focus: distinguish state from output and show the effect of the selection.
29 | CORRECT THE COMPLETE LOGIC
[4 suggested marks]
Whole-number inputs must be from 0 to 30 inclusive. This fragment is intended to retry invalid inputs. Identify its logical error and explain precise corrections. Assume Value is declared INTEGER.
REPEAT
INPUT Value
UNTIL Value < 0 OR Value > 30
OUTPUT "Accepted: ", ValueSample answer: The UNTIL condition currently stops for an invalid value rather than a valid one. For example, thirty-one ends the retry and is then labelled accepted. Also, OR combines the outside-range conditions, rather than requiring both valid bounds. Replace the whole condition with Value >= 0 AND Value <= 30: REPEAT now stops only when both inclusive bounds hold. Test minus one then zero, and thirty-one then thirty, to confirm retry and endpoint acceptance.
- Identify wrong stopping sense with its effect: one mark.
- Replace lower comparison with Value >= 0: one mark.
- Replace upper comparison with Value <= 30: one mark.
- Combine valid bounds with AND and explain that both must hold: one mark.
Writing focus: the original condition describes being outside the range, but UNTIL needs the acceptance condition here. The correction is one coherent replacement; a different correctly reasoned valid condition can also work.
30 | TEST DATA AND EXPECTED RESULTS
[4 suggested marks]
A quantity must be a whole number greater than 12 and less than 18. Suggest a normal test and all four boundary tests. State the expected result for each boundary value, and explain why checking only 15 is insufficient.
Sample answer: Fifteen is a representative normal input and should be accepted. Boundary values are twelve: reject; thirteen: accept; seventeen: accept; eighteen: reject. Testing only fifteen cannot distinguish the correct exclusive rule from a faulty inclusive twelve-to-eighteen rule, because both accept fifteen. Endpoint-focused tests reveal that difference.
- Valid representative normal test with acceptance: one mark.
- Lower boundary pair twelve/reject and thirteen/accept: one mark.
- Upper boundary pair seventeen/accept and eighteen/reject: one mark.
- Explain why a middle value misses endpoint faults: one mark.
Writing focus: relate each chosen input to a rule or possible fault.
31 | AMENDMENT AND REGRESSION CHECKS
[4 suggested marks]
An attendance algorithm is amended to process four classes and output the mean per participating class, where participating means positive attendance. Zero remains valid. Explain where to initialise and update ParticipatingClasses, why division needs a guard, and one retained rule that should be regression-tested.
Sample answer: Initialise ParticipatingClasses to zero before the class loop so earlier counts are retained. After each accepted input, increment it by one only when Attendance is greater than zero; this excludes invalid attempts and zero-attendance classes. After all classes, divide only if that count is positive, because otherwise the denominator is zero. Retest the original inclusive input range, for example confirming that zero and thirty remain accepted after the amendment.
- Initialisation before repetition with reason: one mark.
- Positive accepted-input count update inside repetition: one mark.
- Guard before division with zero-denominator reason: one mark.
- Relevant retained rule and specific regression check: one mark.
Writing focus: link the location of an instruction to the effect it prevents.
32 | CONSTRUCT A COMPLETE SOLUTION
[6 suggested marks]
A school collects attendance from four classes. Every entry is a whole number from 0 to 30 inclusive; repeat input until valid. Output total attendance, the count of classes with positive attendance and their mean. If none has positive attendance, output No participating classes instead of a mean. Demonstrate a solution by writing a complete pseudocode algorithm. Then calculate its summary outputs for attempts 31, 12, 0, 18, 0. Assume whole-number input.
One possible solution:
DECLARE Attendance : INTEGER
DECLARE ClassIndex : INTEGER
DECLARE Total : INTEGER
DECLARE ParticipatingClasses : INTEGER
DECLARE Average : REAL
Total ← 0
ParticipatingClasses ← 0
FOR ClassIndex ← 1 TO 4
REPEAT
OUTPUT "Enter attendance from 0 to 30"
INPUT Attendance
UNTIL Attendance >= 0 AND Attendance <= 30
Total ← Total + Attendance
IF Attendance > 0
THEN
ParticipatingClasses ← ParticipatingClasses + 1
ENDIF
NEXT ClassIndex
OUTPUT "Total: ", Total
OUTPUT "Participating classes: ", ParticipatingClasses
IF ParticipatingClasses > 0
THEN
Average ← Total / ParticipatingClasses
OUTPUT "Mean: ", Average
ELSE
OUTPUT "No participating classes"
ENDIFThirty-one is retried for the first class. Accepted values are twelve, zero, eighteen and zero. Summary outputs are Total thirty, participating count two and mean fifteen.
- Appropriate variables/types and both initialisations: one mark.
- Exactly four accepted class values using appropriate repetition: one mark.
- Inclusive range retry nested within class processing: one mark.
- Total and conditional class count updated after acceptance: one mark.
- Final output and guarded mean/alternative: one mark.
- Correct summary outputs for the supplied attempts: one mark.
Other complete, correct algorithms are valid. These grouped practice marks are deliberately broad; they are not an official Cambridge mark scheme.
Writing focus: precise complete instructions demonstrate the solution; a prose description alone does not replace the requested pseudocode.
CHECK YOUR WRITTEN COMMUNICATION
- Did I answer the command word, rather than just name facts?
- For explain, did I show an accurate reason or cause-and-effect link?
- For compare, did I address both things on the same point?
- For evaluate, did I weigh relevant factors and justify my judgement?
- Did I use precise terms and connectives naturally, without repeating or padding?
Self-assess using the suggested content marks, keeping the written total separate from your automatic score. Use the writing checklist to improve an answer rather than adding unofficial language marks.
YOUR NEXT REVISION STEP
Submit sections A and B to see suggested lessons to revisit.
For written work, revisit bubble sort, validation and verification, tracing selection and loops, and complete algorithm amendments as needed.
Use the Topic 7 revision page for coverage of all nine sections and a selectable flashcard list. Choose two weak areas, revisit them and try new examples before retesting. Keep automatic and written scores separate; these are practice results rather than grade predictions.