Question 4: Bake Cake
Draw the environment diagram of the following code.
def square(x):
return x * x
def bake(cake, make):
if cake == 0:
cake = cake + 1
print(cake)
if cake == 1:
print(make)
else:
return cake
return make
cake = square(0)
bake(cake, 29)
You can view the correct environment diagram here.