Gee! Visual C++ is a breeze to use, the latest version at least. If you're masochist or broken, you can download the borland compiler for free from borland.com.
Why don't you enter all the info in a matrix (struct in C)?
number of rows = number of students
1rst column: the names
number of columns = number of results + 1 (total or average) + 1 (name, the 1rst column).
This would work well only if the total/average is always calculated in the same way. Otherwise you would have to ask the user how much each result count on the final grade (ADD a row in your matrix for it, so # of row = # of students + 1).
ie.
test 1 = .3 of the final grade
test 2 = .1
test 4 = .2
test 5 = .5
First ask for the number of students and the number of exams. Define the size and type of your matrix.
Second, ask for value of each exam on the final grade.
Create a first sub where you ask for each of the n student names, one by one.
You might want to do another sub where the user can check for any mistake he could have made and correct them.
Then do another sub where the user enters results, either of one column (exam after exam) or one row (students after students). Again, you can have a nice little sub where the user can double check and correct his input.
Do the maths, export matrix with final grade to text file. (I don't know how to save and retrieve info, but it should be easy to convert to and from a text file.)
[ 09-26-2002, 09:46 PM: Message edited by: flibulzbuth ]
__________________
Boo for president!
|