a. Input names and three test scores of students from the user, terminated by ZZZ,0,0,0, and create

Question:

a. Input names and three test scores of students from the user, terminated by "ZZZ",0,0,0, and create a data file "grades" with records of the following form:

student_name (String), test_1 (Integer), test_2 (Integer), test_3 (Integer)

b. Display the contents of the file "grades" created in Part a. Each student’s record should appear on a separate line and include the total score (the sum of the three tests) for that student. For example, a line of output might be as follows:

R. Abrams     76     84     82     242

c. Modify the program of Part b so that at the option of the user, it displays either the entire contents of the file "grades" or just the record of a specified student. In either case, for each student displayed, also display his or her total test score.

Fantastic news! We've Found the answer you've been seeking!

Step by Step Answer:

Related Book For  book-img-for-question

Prelude To Programming

ISBN: 9780133741636

6th Edition

Authors: Stewart Venit, Elizabeth Drake

Question Posted: