
Patrick B. answered 01/14/21
Math and computer tutor/teacher
1) File stores data on the disk;
THe data can be input into a program OR/And
can be the output results of another program
2) File_handle = OPEN_FILE(filename,file_mode);
if file_handle is valid
while not end of datafile
read/write the record
process the record
store the record in the array
end while
closes the file
endif
3) menu driven:
the list of available actions is displayed
in the menu, a NUMBERED LIST
user/operator selectes the action to perform
by inputting the integer value corresponding
to the action to be performed
other input is gathered
corresponding action performed
results and output returned to use
EX>
Menu
(+) ADD
(-) SUBTRACT
(*) MULTIPLY
(/) DIVIDE
input the math operation followed by the numbers
ex. * 4 5
output 20
ex. + 9 8
output 17
ex. - 12 7
output 5
ex. / 15 3
output 5
ex. / 5 0
ERROR DIVIDE BY ZERO