Imagine you ask a robot to walk to the door and you only say, Go over there. Will it know which way to face, how many steps to take, or when to stop?
Today we will write instructions so precise that even a robot that only does exactly what it is told can reach a goal.
Keep this light. No grid set-up yet. Stand near the door and give one deliberately vague instruction such as Go over there, then ask why a robot would get stuck. Collect two or three pupil ideas about what was missing (direction, number of steps, when to stop).
Nature of STEM: Technologists write precise steps before they touch a device. Today's unplugged work is the same thinking pupils will need when they write code later.
Two words for today.
An algorithm is a clear, ordered list of steps. A bug is a mistake in those steps that makes the plan go wrong.
Look at the demo grid on the floor. The start square is marked, and the goal is two squares ahead and one to the left. Watch the path the teacher points out. What is the first small step you would write?
Project only the short board version (algorithm and bug). Keep this tight so the fail-then-fix model always fits. Decomposition and debugging are named later, after groups have done the floor and desk runs.
Anchor the path question: Before you ask for the first step, stand at the demo floor grid (or on a few taped squares). Point clearly to the start square, the goal square (two ahead and one left from the robot's facing), and the path between them so every pupil can see the same short journey. Do not ask the question while the grid is still empty or off to the side.
| Concept | Why it matters | Example |
|---|---|---|
| Algorithm — a clear, ordered list of steps that solves a problem when followed exactly | A robot (or a computer) cannot guess what you meant; it only does the steps you wrote | Forward, forward, turn left, forward takes a robot from start to goal on a grid |
| Bug — a mistake in the sequence that makes the plan go wrong | Bugs are normal; finding them is part of the work, not a failure | Missing a turn so the robot walks into a wall instead of the goal |
Use the demo floor grid. Think aloud through one full fail-then-fix cycle only:
Misconception to head off: Pupils often write "go to the star" as one step. Allow only forward, turn left, turn right. Vague steps are not allowed because a robot cannot interpret them.
Do not teach all four terms here. After the group runs, label what they did as decomposition and debugging in the share step.
Your group's job: write an algorithm that guides a robot from the start square to the goal on your desk mat.
You may only use three commands: forward, turn left, turn right.
Share the jobs in your group: the writer lays the command cards in order; the reader calls one step at a time; the robot moves the desk token exactly as told, with no helpful guessing; the checker watches for the bug and says which step went wrong. If your group is smaller than four, combine jobs (for example writer and checker).
Predict first: will your first sequence work, or will you need to find a bug? Then test. If it fails, fix one step and try again from the start. Leave your working cards in order on the desk when you finish so you can record them next.
Aim for groups of three or four. One demo floor grid at the front for your earlier model and an optional share run only. Every group works at its own desk grid mat with a small robot token, start/goal markers, one obstacle, and a set of command cards. That way every group writes, predicts, runs and debugs in the same 20 minutes. The floor grid is not a queue for group work.
Robot faces a fixed start direction on every grid. Only the three commands are allowed.
Simpler path: three forwards and one turn. Stretch: add a second turn or a longer route around the wall. Fast finishers write a second algorithm for a new goal square on the same mat.
Fold the watchers in: When one group runs on the floor demo, ask the class Are they right so far? What would you predict for the next step? Watching is real participation — no parallel busywork sheets.
Safety: Walk only on the floor grid, no running. Tape edges can trip — step inside squares. Keep bags and chairs clear. Desk tokens stay on the table.
On your Investigation Journal page, record what your group just tested on the desk mat.
Write your working command list in order (only forward, turn left, turn right). Then write: the step that went wrong, and what you changed.
This is the paper recording beat, straight after the desk-grid runs so the fail-and-fix details are still fresh. Pupils use the Investigation Journal page. Cards should still be laid out on each desk as evidence.
Circulate and check:
If a group's first sequence worked first time, ask them to record a second challenge on the same mat where they deliberately introduced and then fixed a bug.
Do not invent extra columns or boxes on the journal page. Ask only for the working algorithm and the bug note the page is built to hold.
Now we try the same idea on the interactive activity. The robot on screen only understands forward, turn left and turn right.
Help build a sequence that reaches the goal without hitting the obstacle. Predict before we press run. If it fails, spot the bug and fix the step that caused it.
Drive algorithm-sequencer on the IWB in explore mode. Pupils call out the order; you drag the command blocks.
Screen grid is 5 by 5 with a wall — different layout from the desk 4-by-4 mats. Same three commands and the same debug habit, not the same path. Say this once so nobody tries to copy their desk sequence onto the board.
Exact layout on screen (so you can drive it without guessing):
One working route example for you (north side, not to show first): forward, turn left, forward, turn right, forward, forward, forward, turn right, forward. Equivalently south side: forward, turn right, forward, turn left, forward, forward, forward, turn left, forward. Both clear the wall column before turning back onto the goal row. Run once with a deliberate bug (for example only forwards along the middle row so it hits the wall) so the class practises debugging aloud. Then rebuild a working sequence together.
Prompts: Where is the bug? How would you fix it? and What is the smallest change that could work?
Link back to the desk grids: same three commands, same need for precision, same debug habit.
You're previewing this lesson. Get full access to this lesson and hundreds more — each one ready to teach, with interactive activities, printable resources and pupil progress tracking built in.