Question: + Run Code PROBLEM 5 The data below contains students names and their GPAs. It is in a dictionary data structure. You should create a

 + Run Code PROBLEM 5 The data below contains students names

+ Run Code PROBLEM 5 The data below contains students names and their GPAs. It is in a dictionary data structure. You should create a program that takes the data as input and returns a list of names sorted by GPA. You will write two separate functions to do this as instructed below. In 1t student GPA - f 'Jane : 3.2, Ricky :2.5, Bob'4.0, Richt). 4. Geott: 3.9 studentGPA2 = {"Andrew, Andy 32.1, Innenals, ank12.4, Sarky:1,enty3.3) A. First create a function that takes a dictionary, switches the keys and values, and returns a new dictionary. In de reverse Dictionary dicta ROTOR TO CODE MELON B. Create another function that takes the dictionary as an argument, sorts it by GPA, and uses the first function to return a sorted list of names. In ta det listamshyapa (data) FENTO YOUR CON LOW YOUR OUTPUT: In 1 tanes (tudentPA) Itatan (tudent2) CORRECT OUTPUT: 201 Astudents tiky', Jane' in', oft', 'Bob' Ta 125 tont.) L'arcy Andy lank. Yenny Tann', 'Andrew1 Functions.Mo....pynb

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!