from minpiler.std import M

x = 10


def f():
    x = 20

    def g():
        def h():
            global x
            M.print(x)
        h()
    g()


f()

# > print 10

from minpiler.std import M

x = 10


def f():
    x = 20

    def g():
        def h():
            global x
            M.print(x)
        h()
    g()


f()

# > print 10

# > print 10