0%
0 / 10 answered
Using Text Files Practice Test
•10 QuestionsQuestion
1 / 10
Q1
A program needs to read student grades from a text file called "grades.txt" where each line contains a student name followed by three test scores separated by spaces. Example line: "John Smith 85 92 78"
Which code segment will correctly read all data from the file and calculate each student's average, assuming the file exists and is properly formatted?
Which code segment will correctly read all data from the file and calculate each student's average, assuming the file exists and is properly formatted?