1. Engineering
2. Computer Science
3. algorithm solution in pseudocode 1 declare variables yourletter theirletter that...

# Question: algorithm solution in pseudocode 1 declare variables yourletter theirletter that...

###### Question details

Algorithm solution (in pseudocode):

1. Declare variables yourletter, theirletter that hold a single character each.

3. Prompt

4A Convert percentage into single digit

5. Run code two times to get the values of yourgrade and theirgrade and assign the letters to yourletter and theirletter respectively.

6.          if yourletter = ‘E’ or theirletter = ‘E’

Print on the screen "Invalid input data, cannot determine who did better in the test!"

Stop the program returning a 1.
otherwise if yourletter is less than theirletter

otherwise if yourletter is more than theirletter

otherwise

Print on the screen "There is no winner!"

The program must receive a numeric grade and return its corresponding letter equivalent according to the table shown below. Use nested-if statements similar to step 6) to determine the corresponding letter grade. Notice that for letters A and F you will need to specify a range of numbers.

 Number Letter 9 - 10 A 8 B 7 C 6 D 0 - 5 F Other E

------------------------------------------------------------------------------------------------------------------------

Part B (10 points)

Modify the program so that it uses a loop so the user may decide to compare to other students. Use a sentinel or flag to stop the loop.

------------------------------------------------------------------------------------------------------------------------

Part C (11 points)

Modify the above program so that when there is no winner, it prints another message below according to the following criteria:

If the letter grade is B or better display message 1, if the letter grade is C display message 2, if the letter grade is D display message 3, otherwise display message 4. Please run my program and test it with different values to see what messages 1 through 4 are equal to.

Both did very good, congratulations!

Not bad but could be better

Both should improve to avoid seeing me again next semester!

Have you considered another major?

for a B

for a C

for a D

for an