Answered step by step
Verified Expert Solution
Question
1 Approved Answer
Develop a method called normalizeGrades() in Java following the details below: a. The method should accept an array of numeric grades as argument. Each
Develop a method called normalizeGrades() in Java following the details below: a. The method should accept an array of numeric grades as argument. Each grade in the array is a numeric value (of type double) between 0 to 100. b. The method should create an integer array of grades, following: o If a grade in the array is greater than 50, then the method should round the numeric grade to the nearest integer value using Math.round() method, and then again round it to an integer grade to a nearest multiple of 5. o If a grade in the array is less than or equal to 50, then the method should round the numeric grade to the nearest integer value using Math.round() method. c. The method should create a character array of letter grades, using a switch statement by translating the integer grades created in (b) to an array of letter grades of type character, following the grade notation: 100 or 95 or 90 85: 70, 75, 80: 55, 60, 65: 50: 0 to 49: d. The method should print the integer array of grades. e. The method should return the array of letter grades created in (c). For example: If the input array is: {100, 28.2, 83.3, 76.1, 56, 36, 73, 72.49, 62.5, 92.1, 57.5, 49.5, 52.4} A B C D F The method should create and print an integer array: [100, 28, 85, 75, 55, 36, 75, 70, 65, 90, 60, 50, 50] The method should return the character array of letter grades: {A, F, A, B, C, F, B, B, C, A, C, D, D}
Step by Step Solution
★★★★★
3.36 Rating (149 Votes )
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