Question: Write a switch statement to convert a letter grade into an equivalent numeric value on a fourpoint scale. Set the value of the variable gradeValue
Write a switch statement to convert a letter grade into an equivalent numeric value on a fourpoint scale. Set the value of the variable gradeValue to 4.0 for an A, 3.0 for a B, 2.0 for a C, 1.0 for a D, and 0.0 for an F. For any other letter, set the value to 0.0 and display an error message.
Step by Step Solution
3.50 Rating (160 Votes )
There are 3 Steps involved in it
switchletter case A gradeValue 40 break case ... View full answer
Get step-by-step solutions from verified subject matter experts
