print(acts[0].__closure__)
print(acts[1].__closure__)
print(acts[0].__closure__[0].cell_contents)
def makeActions():
acts = []
for i in range(5):
def f(x, a=i):
return a ** x
acts.append(f)
return acts
acts.append(lambda x, a=i: a ** x)