Need help writing A C++ program that reads student details from a text file and calculates respective totals,average and grade. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

Need help writing A C++ program that reads student details from a text file and calculates respective totals,average and grade.

The program should read student details(id,name and 3exam marks) for 9students in a class from a text file. each line will be read and assigned to a struct variable, then store the structs in an array. After reading the file to the array calculate and display:lowest and highest score and the average and standard deviation rounded of to two decimal places. Finally get the grade of each student based on the three exams out of 300. So far ive been able to read from the text file only.

21st Dec 2017, 11:18 AM
Festus Ribiro
Festus  Ribiro - avatar
1 Answer
+ 1
Before reading the file, find a way to organize the data that will be simple to read with a program. Here is my idea for organization: Name:ID,exams-count, exam1, exam2 John Doe:42,3,97,56,87
22nd Dec 2017, 8:41 PM
Lil Taco
Lil Taco - avatar