How do you break a problem into steps
Earlier we said an algorithm is "a set order of steps for solving a problem." But faced with a big problem, that order just doesn't come to mind. The secret is simple: if it won't fit in one bite, break it into smaller pieces of the same kind.
It won't fit in one bite
Being told to clean your whole room feels overwhelming.
You can't think where to start, or in what order.
Big problems are like that: seen as one lump, they're too big to fit in one bite.
Press the big problem and it breaks into small pieces. Clean the room → desk · bed · floor · bookshelf.
The whole room felt overwhelming, but split into desk, bed, floor, and bookshelf, it suddenly looks doable.
That's the first step in solving a big problem: break it into small pieces.
The same kind of problem, only smaller
Look closely at the pieces and you'll notice something interesting.
Each piece is still "cleaning." Cleaning the room has simply shrunk into cleaning the desk.
A piece is the same kind of problem as the original, only smaller.
Press a piece to look inside. Inside, too, it's the same kind of problem, only smaller. Cleaning the desk = cleaning.
This is useful because if you know how to solve the big problem, you can solve the small pieces the same way.
You don't need to learn a new method.
Since it's the same kind of problem, you just use the method you already have, on a smaller scale.
Put the pieces in order
Breaking it up isn't the end. The pieces have an order too.
If there's stuff all over the floor and you sweep the floor first, things falling from above will make a mess again.
The right order is to clear the desk and bed first and sweep the floor last.
Press the pieces in the order you'd handle them. Doing the top (desk, bed, bookshelf) first and the floor last is correct.
With the order right, the pieces don't get in each other's way.
No more cleaning up after a mess an earlier piece made.
Just as we saw in Lesson 1, the same pieces in a different order give a different result.
Combine the pieces' answers
You've solved every piece: the desk, the bed, and the floor are all clean.
But wait, you only solved the pieces. Isn't the room still unfinished?
No. Once all the pieces are solved, together they make a clean room.
Press the solved pieces in turn and they combine into one. When all the pieces' answers are gathered, that's the answer to the big problem: a clean room.
So combining doesn't happen by itself.
Gathering the pieces' answers and joining them into one is a step in its own right.
Breaking it up, solving in order, and combining all have to work for the big problem to really be solved.
Summary: break, same kind, order, combine
When a big problem feels overwhelming, remember these four beats.
First, break it into smaller pieces of the same kind. Second, see that each piece is the same problem.
Third, set the right order. Fourth, combine the pieces' answers.
This is where computational thinking begins.
Press the four beats in turn to sum up the key ideas. Break → same kind → order → combine. One picture for handling a big problem.
Now you don't need to fear any big problem: if it won't fit in one bite, break it up.
But when there are many pieces, the order in which you do them really matters.
In the next lesson, we'll look at lining things up: sorting.