Question: This is in PYTHON! Write a program that keeps a dictionary in which both keys and values are strings - names of students and their

This is in PYTHON!

Write a program that keeps a dictionary in which both keys and values are strings - names of students and their course grades. Prompt the user of the program to add or remove students, to modify grades, or to print all grades.

 (A)dd, (R)emove, (M)odify, (P)rint all, or (Q)uit? 

When Add is selected prompt

 Enter the name of the student: 
 Enter the student's grade: 

When Remove is selected prompt

 What student do you want to remove? 

If the student doesn't exist display

 Sorry, that student doesn't exist and couldn't be removed. 

When Modify is selected prompt

 Enter the name of the student to modify: 

then display

 The old grade is XX 

where XX is grade to be modified, and prompt

 Enter the new grade: 

If the student name doesn't exist display

 Sorry, that student doesn't exist and couldn't be modified. 

When Print is selected the output should sorted by name and formatted like this:

 Carl: B+ Joe: C Sarah: A Francine: A 

Finally, when Quit is selected display

 Goodbye! 

Add error checking to the menu, whereas an illegal choice results in the following message

 Sorry, that wasn't a valid choice.

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!