chiark
/
gitweb
/
~ian
/
hippotat.git
/ blob
commit
grep
author
committer
pickaxe
?
search:
re
e1a15680663d37e39835087ec2b9a0be1aa20076
[hippotat.git]
/
test.py
1
#!/usr/bin/python3
2
3
def hi(th, x):
4
print('hi %s %s' % (th, x))
5
6
def rt():
7
global g
8
g = { }
9
while len(g) < 3:
10
newthing = object()
11
newfunc = lambda x: hi(newthing, x)
12
g[newthing] = newfunc
13
14
rt()
15
print(repr(g))
16
for v in g.values():
17
v(24)