Term 3 — Lessons 8–10

Thinking like a computer with precise algorithms, drawing flowcharts, and using selection to programme a micro:bit score counter.

Lesson 8 — Think Like a Computer: Algorithms

What you'll achieve: expose the gaps in a hand-written algorithm using the sandwich challenge, then plan a precise 12-step algorithm of your own.

BrowserBooklet
Algorithm
A precise set of step-by-step instructions for solving a problem.
Precision
Being exact and leaving nothing open to guessing.
Debug
Finding and fixing a mistake in a set of instructions or code.

I Do

Watch your teacher write a vague "how to make a sandwich" algorithm on the board, then follow it literally and exactly — doing something silly when a step is unclear.

We Do

As a class, spot every gap in the teacher's sandwich algorithm and rewrite one unclear step so it's precise.

You Do

  1. Write your own step-by-step sandwich algorithm — be as precise as you can.
  2. Swap algorithms with a partner.
  3. Your partner follows your instructions exactly and literally.
  4. Note down every gap or mistake that gets exposed.
  5. Debug your algorithm by rewriting the unclear steps.
  6. Use the 12-step planning grid to plan a new everyday algorithm of your choice.

Before You Go

What did you learn today? Explain in your own words.

Exit Ticket

Show what you've learned today.

Open Exit Ticket →

Lesson 9 — Flowcharts

What you'll achieve: trace a ready-made flowchart and design your own using the correct shapes.

Diagrams.netBrowser
Flowchart
A diagram that shows the steps of an algorithm using connected shapes.
Oval
The shape used to show the start or end of a flowchart.
Decision
A diamond-shaped step that asks a yes/no question and branches the path.

I Do

Watch your teacher go through the flowchart shapes reference: an oval for start/end, a parallelogram for input/output, a rectangle for a process, and a diamond for a decision.

We Do

As a class, trace through the "what to eat for lunch" flowchart on the algorithms resource page, following each shape and answering the decision questions together.

You Do

  1. Choose your own everyday decision, e.g. what to wear or which route to school.
  2. Sketch it out on paper first using the correct flowchart shapes.
  3. Open diagrams.net and build your flowchart digitally.
  4. Include at least one diamond decision shape with two branches.
  5. Check your flowchart with a partner — can they follow it?

Before You Go

What did you learn today? Explain in your own words.

Exit Ticket

Show what you've learned today.

Open Exit Ticket →

Lesson 10 — micro:bit — Buttons & Selection

What you'll achieve: build a score counter on your micro:bit that resets and detects a win, using IF statements.

micro:bitMakeCode
Selection
Code that makes a decision using IF, so different things happen depending on a condition.
IF statement
A block that only runs its code when a condition is true.
Variable
A named container that stores a value, like a score, that can change.

I Do

Watch your teacher build an IF block that reacts to "button A pressed", and explain selection — code that only runs when a condition is true.

We Do

  1. Create a "score" variable together.
  2. Build: IF button A pressed, change score by 1.
  3. Add: show number score, so you can see it update.

You Do

  1. Build your own score counter: button A pressed adds 1 to score.
  2. Add a reset: IF button A and button B are pressed together, set score to 0.
  3. Add a win condition: IF score = 10, show a happy icon.
  4. Download it and test all three behaviours on your micro:bit.

Before You Go

What did you learn today? Explain in your own words.

Exit Ticket

Show what you've learned today.

Open Exit Ticket →