Op 2005-02-18, Steven Bethard schreef <[EMAIL PROTECTED]>: > Paddy McCarthy wrote: >> x=lambda : A < B >> y=lambda : C+6 >= 7 >> > [snip] >> >> Z=lambda : (A<B) and (C+6>=7) > > See "Inappropriate use of Lambda" in > http://www.python.org/moin/DubiousPython > > Perhaps your real example is different, but notice that > <name> = lambda <args>: <expr> > is equivalent to > def <name>(<args>): > return <expr> > except that the latter will give your function a useful name. No reason > to use the *anonymous* function construct to create a *named* function.
So and if I have code like this: f = lamda x:x for g in some_iter: f = compose(g,f) Do you still think that one should use a named function in this case? -- Antoon Pardon -- http://mail.python.org/mailman/listinfo/python-list