Reputation: 99
Why the following code doesn't work as it is but would work after commenting either print(x) or x=1?
print(x)
x=1
def f(): x = 1 def g(): print(x) x = 1 g() f()
Upvotes: 0
Views: 34