studenAnswers.txt Smith A B совсD вввCD АААВD DAD Jones A C срссD АВВСD АААВ С СAD Plumlee A ВсD вс DABBC DAAAB СDАС Bigelow C B совсD АВВCD A А АВСDAD North A B CDВCDA ВВCDAA АВСDА D Rix A B DD...


See attached images


C++


studenAnswers.txt<br>Smith A B совсD вввCD АААВD DAD<br>Jones A C срссD АВВСD АААВ С СAD<br>Plumlee A ВсD вс DABBC DAAAB СDАС<br>Bigelow C B совсD АВВCD A А АВСDAD<br>North A B CDВCDA ВВCDAA АВСDА D<br>Rix A B DD BCDABBD DADD BCDDD<br>Gaddis A АСD ВС ААВВ С АААВ В ССАD<br>IckySlobongo A A A AA ААА А А АААА А А А ААА<br>correctAnswers.txt<br>АВСD B СDАВ В СDАА АВСD АD<br>

Extracted text: studenAnswers.txt Smith A B совсD вввCD АААВD DAD Jones A C срссD АВВСD АААВ С СAD Plumlee A ВсD вс DABBC DAAAB СDАС Bigelow C B совсD АВВCD A А АВСDAD North A B CDВCDA ВВCDAA АВСDА D Rix A B DD BCDABBD DADD BCDDD Gaddis A АСD ВС ААВВ С АААВ В ССАD IckySlobongo A A A AA ААА А А АААА А А А ААА correctAnswers.txt АВСD B СDАВ В СDАА АВСD АD
Write a program to accomplish the following:<br>One of your professors has asked you to write a program to grade her final exams which consist of 20 multiple choice<br>questions. Each question has one of four possible answers: A, B, C, or D.<br>The file

Extracted text: Write a program to accomplish the following: One of your professors has asked you to write a program to grade her final exams which consist of 20 multiple choice questions. Each question has one of four possible answers: A, B, C, or D. The file "correctAnswers.txt" contains the correct answers for all 20 questions. All 20 answers are written on one line in the file. Write a program that reads the contents of CorrectAnswers.txt into a char array, then reads the contents of another file containing the students' names and answers. This second file is named "studentAnswers.txt" and has the fallowing format: StudentAnswers.txt contains data for an entire class of students. There is one student's information on each line in the file. Each line contains the student's last name followed by student answers to the test questions (always 20 answers). The student's last name will not have any spaces. You may assume it is a single "word". A sample is given below: Smith A BC DBCDBBBCDAAABDDAD Jones A CCDCCDABBCDAAABCCAD A sample of each file is provided on Blackboard for studentAnswers.txt and correctAnswers.txt. For each student in the studentAnswers.txt file the program should determine the number of questions that the student missed, then display the following: (a sample output is given at the end of this assignment) A row of "equal signs" as a separator to clearly show the beginning of each student's separate report. The student name A line which reads "Missed Questions" A line which reads "Question Given Correct" A row of dashes separating the previous two lines from the data list. Below the row of dashes for each student display a list of question numbers that were missed, the answer given, A. and the correct answer. Below the list of missed questions, display if the student passed or failed, and then the percentage of correct answers in parentheses. 70% is a passing grade. Your program should handle any number of students, up to a maximum of 50 students (that is, it should work even if the input file had, say, 10 or 30 students). If the file has more than 50 students, your program should only read the first 50). In other words, your file should read students until it reaches the end of file, or 50 students if the file contains more than 50 students. Note additional requirements below: 1. For the Jones student in the sample output, notice that no questions were missed. In this scenario, you should produce the output as shown (with the title "Missed Questions:" followed by "None". 2. Follow all previous documentation and formatting requirements. 3. You must divide the program into functions. Part of ycur grade will depend on how well your code is structured/divided into meaningful functions. 4. Use formatting tools like setw() and "right" / "left". Do not hard-code spaces between output elements. Sample output for three students is shown below: ==== Student Name: Baker Missed questions: Question Given Correct 2 A 10 B Passed (90% correct) ====-- == Student Name: Jones Missed questions: None Passed (100% correct) Student Name: Lewis Missed questions: Question Given Correct ---- - A 10 B 11 D 12 A 14 B 15 A 16 A. 17 A B Failed (60% correct) ..and so one for each student, up to 50 maximum...
Jun 01, 2022
SOLUTION.PDF

Get Answer To This Question

Related Questions & Answers

More Questions »

Submit New Assignment

Copy and Paste Your Assignment Here