Block coding lesson 6: Shorter programs
US version. US grades and US spelling. · UK version of this lesson
move forward 3 does the same as three move forward 1 blocks. Fewer blocks are quicker to read and to check. A complete 30-minute block coding lesson (Grades K–2), from Unit 2: Bugs and walls. Myrtle the Turtle runs right here in your browser – nothing to install.
- Time
- 30 minutes + 10 min homework
- Grade
- Grades K–2 (ages 5–8)
- You need
- A computer or tablet, squared paper and a pencil
- Graded
- Instantly, with explanations
For parents: how to use this lesson
You don't need to know anything about coding. The lesson explains each step on screen, the way Mr Babbage, our Head of Computing, likes it: watch Myrtle first, then have a go. Programs are made from blocks – no typing – and every answer is graded straight away.
- Before the screen: Find something at home with lots of repeated steps (a recipe, a dance) and say it in fewer words.
- Press Start the lesson below and watch the worked examples together. Press Run and say what each block does before Myrtle does it.
- Let your child do the practice on their own. When Myrtle goes the wrong way, that's a clue, not a failure – press Run again and watch which block it is on.
- Finish with the talk question: “Why might a programmer want a shorter program?”
- Later that day or the next day: the homework (10 minutes), then a practice test.
Watch out for
- Thinking a longer program is "more right". If both reach the star, both are right – the shorter one is just neater.
- Adding the numbers wrongly when joining blocks. Count the squares on the grid to check.
Miss Lovelace's tip for home: ask your child to be Myrtle. Read out the blocks and let them walk it on the floor. If they can act it out, they understand it.
What your child will learn
Learning goal: use bigger numbers to make programs shorter.
Success looks like
- I can use bigger numbers to make programs shorter.
- I can compare two programs that do the same thing.
- I can say why a shorter program can be better.
Key words
efficient · shorter · compare · same result
The big ideas (for the adult)
move forward 3 does the same as three move forward 1 blocks. Fewer blocks are quicker to read and to check.
Two programs can both be right. We can still ask: which one is easier to read and fix?
A worked example
move forward 1 turn right move forward 1
Press Start the lesson to watch the turtle run it.
The lesson, step by step
| Part | Time | How it is checked |
|---|---|---|
| Starter | 4 min | Graded by Classfern |
| Teach | 7 min | Watch, talk and try |
| Worked example and try it | 6 min | Graded by Classfern |
| Practice | 9 min | Graded by Classfern |
| Wrap up | 4 min | Graded by Classfern + self-check |
The lesson
It runs here on the page. No sign-up and no names – progress is kept only in this browser. Each visit picks a new mix of questions.
Homework
10 minutes: 4 questions – work out what Myrtle does, then build or fix a program – and a short reflection. New questions every time, all graded instantly. Away from the screen: find something at home with lots of repeated steps (a recipe, a dance) and say it in fewer words.
Practice tests
- Block Coding: Bugs and Walls Practice Test (Grades K–2)10 questions · graded instantly
- Block Coding: Mixed Practice Test (Grades K–5)15 questions · graded instantly
All computer science practice tests · All 18 block coding lessons
Curriculum
CSTA K–12 Computer Science Standards (2017), grades K–2: 1A-AP-10 – Build programs with sequences and simple loops; 1A-AP-12 – Plan a program's order of events, goals and expected outcomes.
The standard codes are CSTA's; the descriptions are our own words.
Our lessons, blocks and questions are our own. They are not written or endorsed by any government department, testing agency or exam board.