This preview shows page 1. Sign up to view the full content.
Unformatted text preview: An algorithm for main may look like the following: Declare variables Call file open function Call read record function // to read data for one employee loop while there is more data Call verify data function if data verified call process one employee function call print employee function call print table function call print to monitor function otherwise call print error function call read record function end loop Call print final report function Close files Each one of these functions may call other functions to do their tasks such as calculate salary, calculate tax, and ....
View Full Document
This note was uploaded on 11/01/2009 for the course CS 101 at USC.