Question: 4. Filename: assign2-8.py Write a function called removekeys that accepts two parameters: a dictionary and a list. The removekeys should remove all the keys contained

 4. Filename: assign2-8.py Write a function called removekeys that accepts two

4. Filename: assign2-8.py Write a function called removekeys that accepts two parameters: a dictionary and a list. The removekeys should remove all the keys contained in list from the dictionary and return the new dictionary: dictionary = { "kl" : "1", "k2" : "62", "3" : "3", "k4" : "14" } keysList = ["2", "K4"] H:\>python C:\Users aslsabbaghpourhokma\Documents\IT2431\Module2\assign2-8.py Original dictionary: {'ki': 'vi', 'k2': 'V2', 'k3': 'v3', 'k4': '4'} Updated dictionary: {'ki': 'vi', 'k3': 'v3'}

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!