Answered step by step
Verified Expert Solution
Link Copied!

Question

1 Approved Answer

in c++ Program #6-Arrays (student averages) You are to write a program that will calculate the grade averages for students in a course. You will

in c++

image text in transcribedimage text in transcribed

Program #6-Arrays (student averages) You are to write a program that will calculate the grade averages for students in a course. You will read the data from a file called studentScores.dat. Assume a maximum of 100 students. Copy these files to your csc135 directory from the following public directory: cp lexport/home/public/carelli/cscI35/lnClass/studentScores.dat studentScores.dat cp lexport/home/public/carelli/cscI35AnClass/arrays arrays The first file is the data file. The second file is a working executable that you can run as an example of how the program should work. The data file layout is: SID test test2 test3 progl prog2 prog3 prog4 prog5 prog6 final Note that the tests and final are each worth 100 points while the programs are each worth 50 points. What you should do First, name your program: arrays.cpp In the program, read the data from the file, ine by line, for each student. For each line read, store the student's id number (SID) into an array, compute that student's average (see below) and store the average in a second, parallel, array. Then, using the computed average, determine the appropriate letter grade and store this into a third, again parallel, array. Continue in this manner until all lines have been processed and the data has been stored in the three parallel arrays. This The program should output each student's SID number, course average, and grade for the course It should be neatly formatted with a proper header and with uniform precision for the averages. Columns should line up and be readable and consistent. This must be done in a function. You will then compute the number of A's, B's, C's. D's, and F's for the course and display this Finally, compute and display the overall average for the entire class. This must he done in a tion as well, for a total See the next page for directions on how to compute the average and determine letter grades

Step by Step Solution

There are 3 Steps involved in it

Step: 1

blur-text-image

Get Instant Access to Expert-Tailored Solutions

See step-by-step solutions with expert insights and AI powered tools for academic success

Step: 2

blur-text-image_2

Step: 3

blur-text-image_3

Ace Your Homework with AI

Get the answers you need in no time with our AI-driven, step-by-step assistance

Get Started

Recommended Textbook for

Oracle Database 19c DBA By Examples Installation And Administration

Authors: Ravinder Gupta

1st Edition

B09FC7TQJ6, 979-8469226970

More Books

Students also viewed these Databases questions