Assignment 3 - Student Grades Using a 2-Dimensional Array

due January 30th

The purpose of this assignment is the use of 2-dimensional arrays, reading and writing text files, writing functions, and program planning and development.

You will read a data file and store all of the input data in a two dimensional array.  You will perform calculations on the data and store the results in the 2 dimensional array.  You will sort the array and print the results in a report.

Instructions

You will read in the same input file used in assignment 1, partially shown below. This 50 record file consists of a (8-digit numeric) student id, 10 assignment's points, midterm points, lab exercise points, final points, and CodeLab points. All of the input data, calculated totals, percents, and grades (and plus or minus) must be stored in only one 2 dimensional array.  The specifications for determination of the grades is the same as assignment 1 (or the course syllabus). Your output reports should be "very similar" to the output shown below.  The point totals, percents, and grades must be follow the exact calculations.  This is the same as assignment 1.  You are to produce two output reports, one sorted by student id and one sorted by total points (in decending order).  The two output reports must be written to separate files.

The Student Data Input File

77997913 38 19 16 16 16 20 20 16 20 16 16 56  60  3
87969978 30 20 11 14 19 11 13 14  8 19 10 60  77  7
81564051 21 14 12 11 18  9 17 11 15  9 20 76  90  6
25744204 37 18 16 19 14 16 13 16 15 17 20 68  74  8
53057551 24  9 12 15 10 15 11 20 16 17 20 22  62  8
49778442 31  9  8  6  7 20 10 16  7 16  5 79  45 10
01234567 17 19 18 15 19 14 14 17 15 16 20 37  65  5
34664035 38 20  7 15 20 17 15 16 16 16  5 34  83  9
50077769 28 10 20 13 17 20 13 18 19 11 18 55  99  6
94439268 39 17 18 17 17  7 19 10 20 18 14 77  82  5
...

Output Report Sorted by Student Id

Stdnt Id  Ex  -------- Assignments --------  Tot  Mi  Fin  CL  Pts  Pct  Gr
--------  --  -----------------------------  ---  --  ---  --  ---  ---  --
01234567  17  19 18 15 19 14 14 17 15 16 20  153  37   65   5  277   69  D+
25744204  37  18 16 19 14 16 13 16 15 17 20  151  68   74   8  338   85  B
29469155  36  19 17 19 14 18 16  8 16 16  5  143  68   68   1  316   79  C+
31904387  26  16 14 10 19  7 11 13 18 15 10  126  44   40   7  243   61  D-
34664035  38  20  7 15 20 17 15 16 16 16  5  142  34   83   9  306   77  C
45809717  32  19 14 14 20 20 19 18 17 14 17  158  50   55  10  305   76  C
47715766  37  20 19  9 19 15 16 16  7 19 18  151  62   95  10  355   89  B+
49778442  31   9  8  6  7 20 10 16  7 16  5   99  79   45  10  264   66  D
49944436  35  13 20 13 12 17 16 16 18 18  6  143  50   68   5  301   75  C
...


Output Report Sorted by Total Points (decending)

Stdnt Id  Ex  -------- Assignments --------  Tot  Mi  Fin  CL  Pts  Pct  Gr
--------  --  -----------------------------  ---  --  ---  --  ---  ---  --
87654321  37  20 19 20 19 20 19 20 19 20 19  176  78   98   9  398  100  A+
96618874  27   6 14 14 19 15 20 20 20 14 20  156  77   98   9  367   92  A
62946127  22  19 14 19 20 20 19 20 20 20 14  171  63   97   8  361   90  A-
54394937  32  19 20 16 11 19 19 17 13 14 10  148  78   93   8  359   90  A-
47715766  37  20 19  9 19 15 16 16  7 19 18  151  62   95  10  355   89  B+
81169639  35  20 17 17 15 19 17 11 13 17 16  151  66   96   7  355   89  B+
94439268  39  17 18 17 17  7 19 10 20 18 14  150  77   82   5  353   88  B+
84855076  38  20 15 17 16 11  6 19 20 20 15  153  60   94   8  353   88  B+
97467762  34  13 20 16 14 18 13 19 16 11 18  147  80   81  10  352   88  B+
...


Program requirements

  1. You must use a 2-dimensional array for all of the data.
  2. Your solution must include at least 5 functions.  And ...
  3. All files must be checked for a successful open.
  4. Email only your source code.