Write python code for following: 1) Produce a list that contains the prime numbers below 1000 (recall Eratosthenes' sief). 2) Invert a dictionary, assuming the values are unique; i.e., create another dictionary whose keys are the values of the first dictionary, and vice versa. Try your code on d = {"1":1, "2":2, "3":3}; it should produce d_inv = {1:"1", 2:"2", 3:"3"}, modulo order. What if the assumption of unique values is not satisfied? Try d = {"1":1, "2":2, "3":3, "4":3} (To get started, initialize d_inv = dict()) 3) Write a python function that applies to trees built from lists with numbers in the leafs. The function should double the values of the leafs. Example: [[[3]],[1,[2]]] ==> [[[6]],[2,[4]]] * / \ / \ * * / / \ / / \ * 1 * / / / / 3 2 The action of the function should be in place, i.e., it should modify the incoming list, not create a new one. Recommendation: Use recursion, i.e., have the function call itself; it's easy! The syntax for defining functions is as follows: def f(x): <<>> ^^^ blank line for termination ^^^ [If 3) does not make sense, wait till next class.]