Question: Question no. 6: Complete the function, so that if you don't have a key return 999. [10 points) # Code goes here def get from(dictionary,

 Question no. 6: Complete the function, so that if you don't
have a key return 999. [10 points) # Code goes here def

Question no. 6: Complete the function, so that if you don't have a key return 999. [10 points) # Code goes here def get from(dictionary, keys): values = ? #complete your code here return values #should return 999 if key doesn't exist print(getfrom(dictionary=d, keys='z')) Question no. 6: Complete the function, so that if you don't have a key return 999. (10 points) # Code goes here def getfrom(dictionary, keys): values = ? #complete your code here return values #should return 999 if key doesn't exist print(getfrom(dictionary=d, keys='z')) Question no. 7: Complete the function, so that if you don't have a key return 999 and add 999 to dictionary? (10 points) # Code goes here def get from(dictionary, keys): values = ? #complete your code here return values #should return 999 if key doesn't exist and should add to dictionary as well print(getfrom(dictionaryd, keysu'z')) # Now this shouldn't throw error as 'z' is now set to dictionary print(d['z'l)

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!