Question: PYTHON PROBLEM Takes info and returns the academic class with the people in each class 1 from collections import defaultdict 2 3 def ppl_in_class(info str:f
PYTHON PROBLEM
Takes info and returns the academic class with the people in each class

1 from collections import defaultdict 2 3 def ppl_in_class(info str:f (str,str))) -[(str, [str])]: 4 return 6 if name'main' 7 def check_ans (ans, right_ans): 8 if (ans -right_ans): 9 10 print 'RIGHT Answer! else: print( 'WRONG Answer!) print('input answer was-, ans) print(' right answer is-, right_ans) 12 13 14 15 info= { 'B10-100': {("John', 'A'), ('Danny.', 'C'), (Konny.', 'B')), 16 17 18 19 20 check_ans (ans, [('PHYS-1', [ 'Angela', 'John ']), ( BIO-100', ['John', PHYS-1": ('John', B'), ('Angela', 'A')>> print(info,info) ans ppl-in-class(info) print answer ans) 'Konn Danoy)])
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
