Programming Assignment 7

 

 

The USC Bowling team needs your help.  Write a program to do the following things:

 

1.         Open an input file called prog07.dat and an output file called prog07.out.

 

2.         Read the number of games bowled per student.

 

3.         Use a for loop to read and process the team members’ scores.  For each game, also determine the Team Ave.

 

3.         Print the final averages, maximums, and minimums for the team members - and for the team as a whole.

 

Use the following input:

 

4

Jan       Jean      Jerry

200       150       160

200       175       170

200       200       180

200       225       190

 

 

Your output should look like the following:

 

 

           USC BOWLING TEAM

           --- ------- ----

 

Game      Jan       Jean      Jerry     Team Ave

 1        200       150       160       170

 2        200       175       170       182

 3        200       200       180       193

 4        200       225       190       205

---       ---       ---       ---       ---

Ave       200       188       175       188

Low       200       150       160       170

High      200       225       190       205

 

 

 

Make sure your program works correctly.

 

 

 


Back to the Main Menu