Some "pythonic" suggestions for Python

Chris M chris.monsanto at gmail.com
Fri Nov 9 10:59:51 EST 2007



Multi-return value lambda? Just so you know, there is no concept of
returning more than one value from a function.

def a(): return 1, 2

returns one value - a tuple of (1, 2).

lambda: (1, 2)

does the same thing.




More information about the Python-list mailing list