Grade by GradeEssential student suppliesSign in
CS. Computer Science · Computer Science: Order and Follow Instructions

Does the Order Matter?

AB SC 1: different orders AB SC 1: relate to outcomesAbout 25 minutes
Learning goals
  • I can test steps in a different order.
  • I can tell if a new order still gives the desired outcome.
  • I can explain why some steps can be swapped and others cannot.

Words to know

swap
Change places. The first step goes second and the second step goes first.
test
Try something to find out what happens.
compare
Look at two things to see how they are the same or different.

Test it and see

In the last lesson, mixing up the steps changed the outcome. But is that always true?

Scientists find out by testing. You can test too:

  1. Follow the steps in the first order. Look at the outcome.
  2. Swap two steps. Follow the new order. Look at the outcome.
  3. Compare. Are the outcomes the same?

If both orders give the desired outcome, the order does not matter for those steps. If not, the order does matter.

Worked example

Fruit on a stick

Jada makes a fruit snack on a stick. She slides on a strawberry, a banana slice and a grape. Her desired outcome is a stick with 3 fruits to eat. Then she makes a second one in a different order: grape, strawberry, banana. Does the order matter?

  1. Order A: strawberry, banana, grape. Outcome: a stick with 3 fruits.
  2. Order B: grape, strawberry, banana. Outcome: a stick with 3 fruits.
  3. Compare: both sticks are a fruit snack, so both reach the desired outcome.

No. For this goal, the order does not matter.

Two orders on the stickOrder ASBGa fruit snackOrder BGSBa fruit snackS = strawberry, B = banana, G = grapeGoal: a stick with 3 fruits. Both orders work!
The fruit is in a different order on each stick, but both give the desired outcome: a fruit snack.

The goal decides

Now Jada's little brother wants a stick that looks exactly like his picture card: strawberry, then banana, then grape. Now the order does matter! Order B does not match the picture.

So always ask: What is the desired outcome? The goal tells you if the order matters.

Worked example

Bedtime steps

Kai's bedtime steps are: put on pyjamas, read a book, turn off the light. Test two new orders. Does each one still work?

  • New order 1: read a book, put on pyjamas, turn off the light.
  • New order 2: turn off the light, put on pyjamas, read a book.
  1. New order 1: Kai reads, then changes, then the light goes off. He ends up in bed, in pyjamas, in the dark. It works!
  2. New order 2: the light goes off first. Now it is dark, and Kai cannot see the pages of his book.
  3. So pyjamas and reading can be swapped, but turning off the light must stay last.

Order 1 works. Order 2 does not.

OrderDesired outcome?
pyjamas, book, light offyes
book, pyjamas, light offyes
light off, pyjamas, bookno: too dark to read
pyjamas, light off, bookno: too dark to read
Kai's tests. Only the orders that keep "light off" last give the desired outcome.

Change one thing

When you test a new order, change only the order. Use the same steps and the same things. Then you know the order is what made any difference.

Math puzzle

Adding is like the fruit stick! 3 + 4 = 7 and 4 + 3 = 7. You can swap the numbers and still get the same answer.

Hands-on activity

Order test lab

You need: paper, a pencil and 3 cups of different sizes (big, middle and small).

  1. Goal: stack the cups inside each other so they take up the least space.
  2. Test 1: put the small cup in the middle cup, then put both in the big cup. What happens?
  3. Test 2: try to put the big cup in the small cup first. What happens?
  4. Make a chart with two columns: Order and Did it work? Write or draw your results.
  5. Now change the goal: just put the 3 cups in a row on the table. Does the order matter now?

Your turn

1

How can you find out if the order matters?

2

Jada's goal was a stick with 3 fruits. Did the order matter?

3

When did the fruit order matter?

4

Which bedtime step must stay last?

5

Why did Kai's new order 2 not work?

More practice

1

Goal: a bowl of cereal. Can you swap "get a spoon" and "get a bowl"?

2

Goal: a bowl of cereal. Can you swap "pour the cereal" and "get a bowl"?

3

Does 5 + 2 give the same answer as 2 + 5?

4

When you test a new order, what should you change?

5

Make up two steps that can be swapped.

Check your understanding

Quiz

1.

Jada's goal is a stick with 3 fruits. She changes the order of the fruit. What happens?

2.

Kai's bedtime steps: which one must stay last?

3.

What tells you if the order matters?

4.

You want to test a new order. What should you change?

For parents and teachers

How to help at home:

  • Turn routines into little tests: "Could we swap these two steps? Let's try and see."
  • Keep asking about the goal. The same steps can be order-sensitive for one goal and not for another.
  • Use a simple two-column chart (order, did it work?) to record results. This is early scientific recording.

Common mistakes:

  • Deciding without testing. Encourage your child to try both orders before answering.
  • Changing more than one thing. If the steps or materials also change, you cannot tell what made the difference.