News for hackers. Stuff that matters.
Re:Ask HN: What does Ruby have that Python doesn't? by kaens on Saturday August 23, 2008 @02:38AM (#284509)
A python "lambda expression" can effectively only be a one-liner - basically the return line of a function minus "return".

That is why people consider them castrated - in most languages I'm aware of that have a "lambda" statement, it can be read as "create an anonymous function that executes this body of statements". In python it reads as "perform a simple transformation or calculation on or with these arguments", as that's all it's generally good for.

There are no comments on this comment yet.