GoalName the flowchart symbols and say what each one is used for.
New words
flowchart · a diagram that shows the steps of an algorithm with shapes and arrowssymbol · a shape that has a fixed meaning in a flowchartprocess · a step where the computer works something out or changes somethingdecision · a step that asks a question with two answers, yes or no
Explanation
A flowchart is a picture of an algorithm. Each step sits inside a shape called a symbol, and arrows join the shapes in order. An oval shows where the flowchart starts and where it stops. A parallelogram is used for an input, which is data going in, and for an output, which is a result coming out. A rectangle is a process, where the computer works something out. A diamond is a decision, a question with only two answers. A rectangle with two extra lines down its sides is a sub-routine, a small set of steps that has its own name. The colours do not matter, but the shapes always mean the same thing.
Shape
Name
What it is used for
oval
start or stop
the first and the last step
parallelogram
input or output
data going in, or a result coming out
rectangle
process
working something out or changing it
diamond
decision
a yes or no question
rectangle with two lines
sub-routine
a named set of steps used inside a bigger program
arrow
arrow
shows which step comes next
Worked examples
Ravi’s program asks for a name and then greets the player. Typing the name is an input. Joining the word Hello to the name is a process. Showing the greeting is an output.
Question
Good decision?
Is the door open?
yes: only yes or no
What colour is the door?
no: many answers
A decision must be a question that has only two answers. ‘Is the door open?’ is a good decision, because the answer is yes or no. ‘What colour is the door?’ is not, because it has many answers.
Sub-routines keep big flowcharts tidy. A game flowchart can have one box that says ‘draw a star’. Another small flowchart, kept somewhere else, shows the steps for drawing the star.
Class activity
Symbol cards (no computer): cut five pieces of paper. Draw an oval, a parallelogram, a rectangle, a diamond and a rectangle with two lines on them, and write the name on the back. An adult reads a step and you hold up the right card. Try: ‘the program begins’, ‘the player types a number’, ‘add 5 and 7’, ‘Is the light on?’, ‘show the score’. Then swap: you read and the adult holds up the card. If you have a computer or tablet, find the shapes in a drawing program and draw all five.
Practice
1
Which symbol is used for each step? (a) a pupil types a number, (b) Is the score more than 10?, (c) the program multiplies two numbers, (d) the program ends.
(a) parallelogram, because it is an input. (b) diamond, because it is a decision. (c) rectangle, because it is a process. (d) oval, because it is the stop.
2
Two of the shapes in this flowchart are wrong. Which steps should have a different shape, and which shape?
‘type your age’ is an input, so it needs a parallelogram. ‘add 1 to the age’ is a process, so it needs a rectangle. The oval shapes and the output step are correct.
3
Write the missing symbol name for each step.
Step
Symbol
Show the winner’s name
?
Is the player 10 or older?
?
Add the three scores
?
Use the steps for ‘draw a flower’
?
Show the winner’s name: parallelogram (output). Is the player 10 or older?: diamond (decision). Add the three scores: rectangle (process). Use the steps for ‘draw a flower’: rectangle with two lines (sub-routine).
4
Zara says, ‘The shapes in a flowchart are only decoration. I can use any shape for any step.’ Is she right?
No. Each shape has a fixed meaning, so everyone who reads the flowchart knows what kind of step it is.