Question: IN C++ Problem 2 Overview: In this question, you will write a program that: 1. Reads a .csv file with 5 columns and up to

IN C++ Problem 2 Overview: In this question, you will write aprogram that: 1. Reads a ".csv" file with 5 columns and upto 10 lines containing information on student grades. 2. Stores the informationin an array of structs. 3. Writes the lines into the output.csvIN C++

Problem 2 Overview: In this question, you will write a program that: 1. Reads a ".csv" file with 5 columns and up to 10 lines containing information on student grades. 2. Stores the information in an array of structs. 3. Writes the lines into the output.csv file where the overall student grade is between a particular range. 4. Prints the content of the entire array. Specifics: Create an array that holds the studentData struct objects. Use the following struct declaration: struct studentData { string studentName; int homework; int recitation; int quiz; int exam; double average; }; 2A. Write a function named addStudentData: i. The addStudentData function has the following declaration: // length: Number of items currently stored in the array void addStudentData(studentData students[], string studentName, int homework, int recitation, int quiz, int exam, int length); ii. Instantiate a struct and store the studentName, homework, recitation, quiz, and exam values in it. iii. Assume equal weights amongst everything that needs to be graded. Take the average of the homework, recitation, quiz, and exam for each respective student and store it in the struct. a. student.average = (homework + recitation + quiz + exam)/4; iv. Add the struct to the students array. 2B. Write a function named calcLetter: i. The calcLetter function has the following declaration: char calcLetter(double avg); ii. Write IF-ELSE conditions to assign letter grades based on the following a. >=90: A b. 80-89.9: B c. 70-79.9: C d. 60-69.9: D e. earned which is a(n) " cout ,, (as shown in the sample output) of the students whose is >= lower_bound and

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!