Reinhold Birkenfeld wrote: > or with a default function argument: > > > class Dummy: pass > > def myFun(globe=Dummy()): > try: globe.globe += 1 > except: globe.globe = 1 > > return globe.globe
A quicker way:
def myFun(globe=[0]):
globe[0] += 1
return globe[0]
Reinhold
--
http://mail.python.org/mailman/listinfo/python-list
