Answered step by step
Verified Expert Solution
Question
1 Approved Answer
C ## Done HW3-hyb.docx MGIS 2320 - HW3 Write a console application to allow a user with a valid account number to enter student grades
C ##
Done HW3-hyb.docx MGIS 2320 - HW3 Write a console application to allow a user with a valid account number to enter student grades for an exam and to find out the total and the average. The program will also display grades in descending order. Enter your account number: 123 Enter your account number: 222 Invalid account number Enter the number of students: 5 Enter the grade for student 1: 100 Enter the grade for student 2: 76 Enter your account number: 1234 Enter the grade for student 3. 88 Invalid account number. Enter the grade for student 4: 100 Enter the grade for student S: 90 Enter your account number: abe Grades in descending order: Invalid account number. 100 100 90 88 76 Total is: 454 Average is: 90.8 Requirements First, as a security feature, the program must verify whether the user's account number is valid by comparing the entered number to several existing account numbers stored in an account array (e.g. 111, 222, 333). Hint: Use BinarySearch(). See the example on the slides. 2. If the entered account number is invalid, the program will display an error message (e.g. Invalid account number) and end. If the entered account number is valid, the user can continue. 3. If the user can continue, then the program will ask the user to enter the number of the students and then their grades into a grade array. 4. The program will then display, as a confirmation message, all the grades in descending order. Hint: Use Sort() and Reverse(). s. Finally, the program will display the total and average Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access to Expert-Tailored Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started