When a program starts to get long and complicated, programmers use
flowcharts to divide the program into sections.
We will use Dia to draw the flowchart on the computer.
The arrows between the boxes, diamonds and ellipses show the flow
of the program.
- Open dia from the menu or the command line.
- Click `file->New diagram'
- Pick `Flowchart' from the drop down box in the middle of the Diagram
- Each action that the computer will do goes in a text box
- Each Control Structure (in this case `if') goes in a text diamond
- Each action that the player at the keyboard will do goes in an ellipse