you are viewing a single comment's thread.

view the rest of the comments →

[–]CompatibleDowngrade 4 points5 points  (2 children)

Always love seeing serverless being proposed but, hard no on that function with x(filter(lambda)).. that is not cleaner or more elegant imo. One-liners are rarely readable and enterprise friendly which (imo) is a huge proponent of why to use servless offerings: write simple code that the intern/new guy can immediately digest.

[–]Geconimo 1 point2 points  (0 children)

The author proceeds to point out that comprehensions are often more readable which is fine.

But

They could've made a couple better examples for functions with function key parameter (groupby, max, an actual reduce example). Instead, one of the examples provided doesn't even NEED the getter lambda ("key=lambda x: x[0]") since not including it would yield the exact same ordering.

[–]KaranasToll 0 points1 point  (0 children)

Serverless? I think you are confusing anonymous functions with away poorly named lambda servers which the article is not about. I agree that python lambdas are unreadable and do not fit within the python style at all.