AdvertisementYour brand could be hereYour brand hereOn every Darslab page · students, parents and teachersinfo@darslab.comAsk for pricesPricesinfo@darslab.com
☰ Year plan · Computing

Fill the gaps

Week 7 · 1.3 What happens next? · 3 lessons
1

Find the missing card

Computing 1: Topic 1.3, pp. 33–48
GoalFind the missing instruction in an algorithm or a code and say why it matters.
New words
missing · left outgap · an empty space where a card should be
Explanation

Sometimes an instruction is missing. There is a gap. The robot will not reach the goal. To find the missing card, trace the code on the grid. Stop where the route needs something. Then fill the gap and trace again.

forwardforward??forward
Worked examples
The robot starts at the bottom left, facing up. It must reach the slide. The cards are F F, then a gap, then F F F. The gap must be a turn right.
Start at the bottom, one column from the right, facing up. Reach the kite. The cards are F, a gap, F F. The gap is a turn left.
Start at the top left, facing right. Reach the ice cream. The cards are F F R, then a gap, then F. The gap is one more F.
Class activity

Missing card game: lay out command cards for a short route on a floor grid. Take one card away and leave a gap. A partner finds which card is missing, puts it back, and walks the route. Does the robot reach the goal?

Practice
1
The robot starts at the bottom left, facing up. It must reach the duck. The cards are R F ? F. Which card is missing?
2
The robot starts at the top right, facing down. It must reach the ice cream. The cards are F F ? F F. Which card is missing?
3
The code is X F F GO. The robot must then turn right and go forward one. Which two cards are missing?
4
Why do we trace the code to find the missing card?