We are going to play the robot game: you give the instructions, and the robot does exactly what you say.
I am a robot. I only do exactly what you say, word for word. Tell me how to walk from here to that chair.
Call out one instruction at a time. Watch carefully what I do.
The chair walk went wrong because the steps were not clear enough. Two words for that:
Algorithm — a precise list of steps in a fixed order that gets a job done.
Bug — a mistake in the steps that makes the wrong thing happen.
Next we will write a real algorithm on the floor grid and fix any bugs we find.
We have a floor grid with a start square and a target.
Your job: write an algorithm that walks the robot from start to target, staying on the grid squares.
Allowed words only: forward, turn left, turn right.
Rules: each forward moves one square. Each turn means you stay on the same square and face a new way (a quarter-turn on the spot — watch me show it with my feet).
Agree every step in order in your group. Dry-run it at your table first. Then one group will run theirs with me as the robot. If I go wrong, we debug together.
Now we will build an algorithm on the board. Three command cards are ready: forward, turn left and turn right.
Call out the order you think will get the robot to the goal. We will drag the steps into place, press run, and watch. If it goes wrong, we debug together.
Precise step-by-step instructions existed long before computers. Think of a recipe, packing a school bag, or walking directions from the school gate.
Where else in everyday life do people follow an algorithm? What goes wrong if one step is missing or in the wrong order?
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.