Y
Hacker News
new
|
ask
|
show
|
jobs
by
testapplication
6802 days ago
That should read:
def foo(n): n = [n] def bar(i): n[0] += i return n[0] return bar
Python really needs a scoping syntax to allow assignment to closed variables.