Can someone please review my pseudocode for my class. The criteria for this assignment is:Input names of students from the user, terminated by ZZZ, and
create a data file GRADES with records of the form:
student (string), test1 (integer), test2 (integer), test3 (integer)
In this file, all test scores should be set equal to 0.
[
Process
Get Student Name, Test Score
Create New File “Grades”
Calculate Grade Total
Input
Student Name
Test Scores
Output
Read Grade File, “Student”, “Test1", "Test2”, "Test3", “Total”
Main Module
Declare Student as String
Declare Test1, Test2, Test3, as Integer
While Student <> “ZZZ”
Call Student Grades
Call Calculate Grades
Call Display Grades
End While
End Program
Student Grades
Open “Grades” For Output as NewFile
Write “Enter the student and three test scores separated by commas please.”
Write “Enter “ZZZ” when done
Input Student, Test1, Test2, Test3
While Student <> “ZZZ”
Set Test = 0
Write NewFile, Student, Test1, Test2, Test3
Write “Enter the students name and three test scores.”
Write “Enter “ZZZ” when done.”
Input Student, Test1, Test2, Test3
End While
End Student Grades
Calculate Grades
Declare Total as Integer
Set Total = Test1 + Test2 + Test3
Close NewFile
End Calculate Grades
Display File
Open “Grades” For Output as GradeFile
Read GradeFile, “Student”, “Test1”, “Test2”, “Test3”, “Total”
End Display File
]
Thanks for your help!!