#This causes an error! Because function f accesses a variable called # y, but there is no local variable y in f, and there is no global variable # y. The only y is a local variable in the function called main. def f(x): print(y) return x * 2 def main(): y = 3 z = f(4) print(z) main()