[Edu-sig] Re: Naming in Python
Scott David Daniels
Scott.Daniels at Acm.Org
Wed Feb 2 02:14:22 CET 2005
Kirby Urner wrote:
[ lots of fun and good stuff ]
> class Function:
> def __init__(self, f):
> self.f = lambda x: f(x)
> ...
Here you missed a simplicity bet (one of my two big pet peeves):
class Function:
def __init__(self, f):
self.f = f
...
For the curious, the other peeve is:
def function(...
if expression:
return True
else:
return False
instead of:
def function(...
return expression
--Scott David Daniels
Scott.Daniels at Acm.Org
More information about the Edu-sig
mailing list