Lesson 4: The tester's job (25 min)

Back to the unit

Goal

Children take turns as programmer, bot and tester: the programmer lays instruction cards, the bot follows them exactly, and the tester compares the result with the goal, finds the wrong card and swaps it.

Materials

Per group of three:

Card sets (R = red circle card or red round block; B = blue square card or blue square block):

Set Goal strip Instruction cards (with one bug) Wrong card Fix
A R B R B R B R B R B B B 5th swap for R
B R B B R B B R B B R R B 5th swap for B
C R R B R R B R R B B R B 4th swap for R

A teacher demonstration set: goal R B R B R B; cards R B R R R B (the 4th card should be B).

Steps

Opening (3 min)

Show the three badges. Say: "People who make computer programs often work as a team. Today we have three jobs. The programmer lays out the instruction cards. The bot does exactly what the cards say, one card at a time, no guessing. The tester checks that the result matches the goal, and if it does not, finds the wrong card."

Main activity: build, test, fix (15 min)

  1. Demonstration (4 min). With two children as programmer and bot, lay the demonstration cards R B R R R B in a row. The bot puts down one block for each card, left to right, in a line. You are the tester: hold the goal strip next to the line and touch both, one place at a time. "Red, red. Blue, blue. Red, red. Red... but the goal says blue!" Point to the 4th instruction card: "Here's the bug." Swap it for a blue square card, clear the blocks, and let the bot build again. Check again: it matches.
  2. Groups (11 min). Give each group set A. The programmer lays the six instruction cards in a row (already in order, with the bug in them). The bot builds. The tester compares, finds the wrong card and swaps it, and the bot builds again to check. Then rotate badges and do set B, then set C, so each child has each job once.
    • The bot follows the cards even when they look wrong; that is how the tester can find the bug.
    • A child with low vision can be the tester using raised goal strips and cards, comparing by touch: the round blocks and square blocks feel different, so the built line can be checked by hand, one place at a time.
    • If a group finishes early, the programmer makes their own goal strip and cards, with or without a bug, for the others.

Talk about it (4 min)

Closing check (3 min)

Show a goal strip R B B R B B and instruction cards R B R R B B. Ask: "Tester, which card is the bug, and what should it be?"

Answer: the 3rd card (a red circle) should be a blue square.

Vocabulary

programmer, bot, tester, instruction, bug, fix, check

Differentiation

Safety

Use blocks too big to swallow; no beads or small parts. Clear blocks away between turns so the table stays tidy.

Teacher notes

The three roles come from CS Unplugged's Kidbots activities (see the unit's Sources); the card-and-block task is written for this unit. "Bot" means a robot that follows instructions; the child playing the bot is a person doing a job, not someone being told off. The bug is always in the cards, never in the bot: this is the point to make.