Computing · 30 min
Instructions that really work
Write an algorithm with unambiguous steps and test an edge case.

01
Take a closer look
An algorithm describes a sequence of steps for solving a problem. Unclear instructions can produce different results. A good test also considers empty input or a task that is already complete.
02
Now try it
- Write instructions for sorting coloured cards by colour. Avoid vague words such as “appropriate”.
- Ask another person to follow the instructions. Then test what happens when there are no cards.
03
Think it through
Why is empty input a useful test?
See a suggested answer
It shows whether the instructions end sensibly without elements and avoid requesting a card that does not exist.