←Previous page

05LOOPS · PATTERNS

Spot the pattern.

Before PyBot writes loops, it looks for patterns: shapes that come back in the same order.

LOOK FIRST

A pattern is a part that repeats.

Things come back

Shapes, colors, sounds, or dance steps that come back in the same order make a pattern.

Find the core

The core is the smallest part that repeats. In circle, square, circle, square, the core is circle, square.

A loop repeats the core

Draw the core 3 times and you have the whole pattern. That is what a loop does!

YOUR TURN

Read the shapes.

Try each tiny question. A wrong answer becomes something to review.

0Completed
8Not tried
0Review
01

What comes next?

Which shape goes in the empty space?

02

Find the core

Which part repeats?

03

How many times?

How many times does the core star, square appear?

04

Find the mistake

Which number breaks the pattern?

05

The missing piece

Which shape is missing?

06

Say it as a loop

Which instruction draws this pattern?

07

Fix the pattern

One shape breaks the pattern. Tap it to change it until the pattern is right.

08

Fix the long pattern

Two shapes break this pattern. Find the core first, then tap the wrong shapes to fix them.

Your work is saved here.

Want a fresh start? Clear only this page.

!
BIG IDEA

A loop is a pattern: one core, repeated.

Next, you will write that pattern in Python with for.