← Back to course
1/6
Week 03 Β· The processor

Monday

One instruction at a time
// One instruction at a time, billions of times a second
⏱ about 15 min

Monday: One instruction at a time

A neighbor brings in a tablet that crawls. Rocket swipes through the open apps. "Twelve games and three videos!" he says. "No wonder it is tired."

Raven watches the screen stutter. "What do you notice?" she asks. "It is not stopped. It is just slow."

Nova glows a steady amber. "Inside, one part does all the thinking," she says. "It takes one small step at a time. Would you like a hint? Count how many lists it is reading."

Nova shows the processor as a row of tiny switches. They flip on and off with a ticking clock.

The part that does the thinking

The processor is the part of a computer that follows instructions. Every app is a long list of instructions.

An instruction is one small step. Add two numbers. Compare two numbers. Move a number from one place to another. Draw one dot on the screen.

The processor reads one instruction, does it, and moves to the next. It never skips ahead and never does two at once.

A big job like showing a video is millions of tiny steps. The processor does them one after another, very fast.

A big jobSome of its tiny steps
Add 25 and 17Get 25. Get 17. Add them. Keep 42.
Show the letter AFind the shape of A. Color one dot. Color the next dot. Repeat.
Check a passwordGet the first letter. Compare it. Get the next letter. Compare it.

Taking turns

A processor can only follow one list at a time. When many apps are open, it takes turns.

It does a few steps for one app, then a few for the next. It switches so fast that everything looks like it is happening at once.

With too many lists, each app gets a smaller turn. That is why the tablet in the story crawled.

Closing apps you are not using is a fix a kid may do. Fewer lists means longer turns for the apps you want.

Read one instruction
Do it
Move to the next one
Repeat
How many instructions does a processor do at the same moment?
WHY THIS EXERCISEA processor follows one instruction at a time. It only looks like more because it is so fast.
PUT THE PROCESSOR LOOP IN ORDER
  • ?Do that instruction
  • ?Repeat
  • ?Move to the next instruction
  • ?Read one instruction
WHY THIS EXERCISERead, do, move on, repeat. This loop runs billions of times while you use a device.
WHY DID THE TABLET CRAWL?
  • Read the question.
  • Tap your answer.
The tablet had 16 apps open. Why was it slow?
Which fix may a kid do for a slow tablet?
An instruction is best described as what?
StatementTrue or false?
The processor follows instructions one at a time.?
A processor can skip ahead to the end of a list.?
Showing a video takes millions of tiny steps.?
More open apps means each app gets a longer turn.?
WHY THIS EXERCISEOne step at a time, taking turns between lists. That is why a busy device slows down.
The part that follows instructions is the what?
Every app is a long list of what?
What does the processor do when many apps are open?
Try it
Write a four step instruction list for making a paper airplane.
Read one step at a time to a partner. They may only do that step.
Notice how they cannot start step three before you say it.

Great thinking, Crew Technician! You know how a processor works through a list. Tomorrow you will find out just how fast it goes.