Default parameter of a function is 'global' : Function Default Argument « Function « Python
- Python
- Function
- Function Default Argument
Default parameter of a function is 'global'

def f(x, y=[]):
y.append(x)
return y
print f(23)
Related examples in the same category