test code for enclosing function.
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
variable = 0
def out_function():
variable = 1
def inner_function():
print(variable)
inner_function()
if __name__ == '__main__':
out_function()