Question: IN PYTHON 3.X PLEASE var_a = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j'] var_b = (1, 2, 3, 4, 5, 6, 7,

IN PYTHON 3.X PLEASE

var_a = ['a', 'b', 'c', 'd', 'e', 'f', 'g', 'h', 'i', 'j'] var_b = (1, 2, 3, 4, 5, 6, 7, 8, 9, 10)

dictionary = dict(zip(var_a,var_b))

THE QUESTION: Create a dictionary named other_dictionary. It should have the key-value pairs as dictionary, unless the original value is odd. If so, the value in other_dictionary should be the squared difference of the original value and 10.

Note: to loop through key-value pairs in a dictionary, check out the '.items' method

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!