GoalRead and draw a linear flowchart, and name its inputs, process and output.
New words
linear flowchart · a flowchart with no loops and no decisions, so it flows straight downinput · data that goes into a programoutput · a result that a program shows, says or makesoutcome · what you have at the end of a flowchart
Explanation
A linear flowchart starts at the top and goes straight down to the end. Every step happens once, in the order of the arrows. It has no questions and no loops, so it always follows the same path. To plan one, first write the steps in a list. Then decide which steps are inputs, processes and outputs. Draw the right shape for each step and join the shapes with arrows. Last, test the flowchart with real numbers to check that it works. The result at the end is called the outcome.
Worked examples
Length
Width
Area shown
6
4
24
10
3
30
5
5
25
Nodira’s flowchart finds the area of a table top. Here it is tested with three different pairs of inputs. The path is always the same. Only the numbers change.
Amir plans a cheese sandwich. Getting the bread, butter and cheese is an input. Spreading and putting the slices together are processes. Putting the sandwich on a plate is the output. There is only one outcome: one sandwich.
Flowcharts are not only for computers. A factory can use one to show how a toy is made, and a library can use one to show how a book is lent. Any job with steps can have a flowchart.
Class activity
Plant a bean (no computer): write these steps on six small pieces of paper: get a cup, soil and a bean; fill the cup with soil; make a hole with a finger; put the bean in the hole; cover it with soil; water the soil. Mix the papers up. Put them in the right order, draw an arrow between each pair and draw the correct shape round each step. Which step is the input, and which is the output? If you have a computer or tablet, you can type the steps into boxes and arrange them. If you like, plant a real bean after.
Practice
1
Name the input, the process and the output. What is shown if the user types 250?
Input: type a length in cm. Process: divide it by 100. Output: show the length in metres. For 250 it shows 2.5 metres, because 250 ÷ 100 = 2.5.
2
Put these steps in the correct order and give the shape for each: show the total, type the price of one ticket, start, multiply the price by 3, stop.
Start (oval), type the price of one ticket (parallelogram), multiply the price by 3 (rectangle), show the total (parallelogram), stop (oval).
3
What goes in the missing box? If the user types 8, what is shown?
The missing box is a process: multiply the score by 2. If the user types 8, it shows 16.
4
Is this a linear flowchart? Explain.
No. It has a diamond, which is a decision. A linear flowchart has no decisions and no loops.