Assume that grade is a variable whose value is a letter grade– any one of the following letters: ‘A’, ‘B’, ‘C’, ‘D’, ‘E’, ‘F’, ‘W’, ‘I’. Assume further that there are the following int variables , declared and already initialized : acount, bcount, ccount, dcount, ecount, fcount, wcount, icount. Write a switch statement that increments the appropriate variable (acount, bcount, ccount, etc.) depending on the value of grade. So if grade is ‘A’ then acount is incremented ; if grade is’B’ then bcount is incremented , and so on.

Assume  that grade is a variable  whose value  is a letter grade– any one of the following letters: ‘A’, ‘B’, ‘C’, ‘D’, ‘E’, ‘F’, ‘W’, ‘I’. Assume  further that there are the following int  variables , declared  and already  initialized : acount, bcount, ccount, dcount, ecount, fcount, wcount, icount.   Write a switch statement  that increments  the appropriate variable  (acount, bcount, ccount, etc.) depending on the value  of grade. So if grade is ‘A’ then acount is incremented ; if grade is’B’ then bcount is incremented , and so on.

LANGUAGE: C++

CHALLENGE:

Assume that grade is a variable whose value is a letter grade– any one of the following letters: ‘A’, ‘B’, ‘C’, ‘D’, ‘E’, ‘F’, ‘W’, ‘I’. Assume further that there are the following int variables , declared and already initialized : acount, bcount, ccount, dcount, ecount, fcount, wcount, icount. Write a switch statement that increments the appropriate variable (acount, bcount, ccount, etc.) depending on the value of grade. So if grade is ‘A’ then acount is incremented ; if grade is’B’ then bcount is incremented , and so on.

This content requires that you purchase additional access. The price is $2.99 or free for our Make Life Easier and 30 Days – Not Recurring members.

Purchase this Content ($2.99) Choose a Membership Level