so we can use flow charts to express data flow through a program so again
going back to our cup of tea program and we can express it as a flow chart like
this we start with the symbols here so I'll just put here what the symbols mean
within our flow chart okay so we start with a start which is this kind of
rounded style rectangle almost okay this just signifies the start of our program
okay we can then use an arrow which shows a progress of the data through our
flow chart so I'll go that and the first thing we wanna do is fill the kettle now
filling the kettle is a process okay a process is a thing that happens in the
program okay that's what a process is so if I draw a rectangle that's a really
bad rectangle and fill kettle do my best to squeeze Winer right in here then we
go down to the next part of the program which is another process boil the water
okay and then we go down to the next part of the program which is get our cup
and teabag cup plus teabag okay and then we go to our next part of the process
which is a boiled water and what we can do for this is ball the water for two
minutes so we could make this a decision box okay
so boil water two minutes okay so these are the two minutes up if
it's not we send our arrow back here if it is the two minutes is up then we send
our arrow on to the next and process which is take t-bag out okay out there
we go and and then add milk so again this can be another decision and I'm
quite sure I'm going to squeeze this in what I'll do I think is we'll just move
on to the next part up here okay and we'll put a decision up here mm-hmm
dance not the greatest diamond ever so and
milk until happy with the cover so if we are happy we will go on to the next part
of the program if we're not happy we'll just join that crowd and keep
adding the milk okay but if we are happy what my last part of our process is
drink tea okay and then we'll finish with a stop okay so if you're over the
start and end is this symbol up here so we'll finish with a sort of curvy
rectangle right stop okay just so we know that this is the start of the
program this is the end of the program okay and the only thing we've missed
there really is an input okay so I suppose we could have had
up here so we could have had an input out of milk if we recorded thinking
that's a bit more carefully but an input is normally where a user has to put
something into the program maybe a command like yes/no something on those
lines okay but what we've essentially got here is a flow chart with pretty bad
handwriting for making a cup of tea