Question: Need Help with C++ Data fetching program. Here is the assignment, please provide full code and comments if possible please! Thank you. 1. Your assignment
Need Help with C++ Data fetching program. Here is the assignment, please provide full code and comments if possible please! Thank you.
1. Your assignment is to prompt the user to enter the filename with the path on disk. If the file does not exist in the specified location, your program should exit with a suitable error message. 2. No global variables. All variables must be inside main(). 3. The first thing your program should do is output to the screen a copy of the data read in from the disk file. This is known as echoing the input data. 4. Your program should then calculate and display the average score for males, females, community college students, and university students. Display your results to two places of decimals, and write your program to automatically list your four calculated averages one to a line, along with a suitable label for each result. 5. Finally, your program should calculate and display to two places of decimals the overall average score for all of the students surveyed. (Note: Mathematically, this is NOT the average of the four averages you calculated previously).

Student Survey Assignment: The Oregon Department of Education has commissioned a study to determine if Males or Females score better on a particular test. They also want to study if Community College or University students score better. Researchers have created a data file (scores.txt), which contains the scores attained by the student sample. The first column is the student's name, the second column is the student's gender (M for male, and F for female), the third column indicates Community College (CC) or 4 year (UN), and the last column specifies the score. A specimen of the file scores.txt is attached as part of this assignment. You should download this file to a convenient place on your hard drive. Design Considerations: 1. Your assignment is to prompt the user to enter the filename with the path on disk. If the file does not exist in the specified location, your program should exit with a suitable error message. 2. No global variables. All variables must be inside main(). 3. The first thing your program should do is output to the screen a copy of the data read in from the disk file. This is known as "echoing" the input data. 4. Your program should then calculate and display the average score for males, females, community college students, and university students. Display your results to two places of decimals, and write your program to automatically list your four calculated averages one to a line, along with a suitable label for each result. 5. Finally, your program should calculate and display to two places of decimals the overall average score for all of the students surveyed. (Note: Mathematically, this is NOT the average of the four averages you calculated previously)
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
