What Comes Next? #171

Pattern puzzle 171 card

Challenge type: What Comes Next?  ·  Difficulty: ★★☆☆☆ Easy

Coders spot patterns so they can write loops instead of doing the same thing over and over. Try this one.

Pattern: an arrow pointing down and left, an arrow pointing up and left, an arrow pointing up and right, an arrow pointing down and right, an arrow pointing down and left, an arrow pointing up and left, an arrow pointing up and right, then a question mark. Choices: A: an arrow pointing down; B: an arrow pointing down and right; C: an arrow pointing left; D: an arrow pointing up and right.
What comes next: A, B, C or D?

The pattern in words: an arrow pointing down and left, an arrow pointing up and left, an arrow pointing up and right, an arrow pointing down and right, an arrow pointing down and left, an arrow pointing up and left, an arrow pointing up and right, and then… what?

Your choices

  • A: an arrow pointing down
  • B: an arrow pointing down and right
  • C: an arrow pointing left
  • D: an arrow pointing up and right
Need a hint?

Look at just two arrows next to each other. How far did the arrow turn, and which way?

Did you know? When coders spot a pattern, they can write a loop: a few lines of code that repeat the rule as many times as they like. The answer page shows this pattern as real Python code!

For teachers and grown-ups

Skills practised: Pattern recognition, abstraction, and predicting the next step of a rule.

The big idea: Spotting a pattern lets a programmer replace lots of repeated steps with one short loop.

Questions to ask:

  • What is the rule, in your own words?
  • How many items repeat before the pattern starts again?
  • What would the 20th item be? How could you work it out without drawing them all?

Take it further: Children invent their own pattern with a hidden rule and challenge a partner to find it.