Re:New Machine Learning Gems for Ruby
by cutler on Sunday June 20, 2021 @01:22AM
(#27567349)
... and Clojure. These two stand out as the most elegantly designed creativity-enhancing programming languages. The rest are mainly a set of constraints. Python is the VHS of programming languages with its pathetic lambdas.
[ Parent
| on HN ]
This may surprise you, but using lambda is considered a sign of bad programming practice in Python.
In general, this whole thread completely misses the point Python makes. Do not invite “clever” language (ab)use. Do the straightforward thing.
> This may surprise you, but using lambda is considered a sign of bad programming practice in Python
Only by its BDFL. Most languages consider lambdas to be first class so why not let the user decide?
Because the user makes poor choices, that’s the point - don’t do the clever thing, do the straightforward thing. Lambdas are discouraged in Python, and that’s not just something Guido van Rossum thinks (who, by the way, is not BDFL - there is none anymore and there hasn’t been for a long time now.)
If lambdas are clever then so is most Node.js code. Guido may have stepped down but he was responsible for this "Pythonic" attitude to lambdas. It's like the Python community is parodying Matz with "Guido hates FP therefore we hate FP".
Re:New Machine Learning Gems for Ruby
by arcturus17 on Sunday June 20, 2021 @05:29AM
(#27568481)
Lambda syntax is indeed horrible in Python. I hope some day they do something to fix it… Otherwise I really enjoy the language and the ecosystem.
What do you think about Elixir in this context? Is it not "creativity-enhancing" enough?
Elixir doesn't have an array/vector implementation. Instead it has to borrow Eralng's ugly offering or hack Map with numeric keys as in PHP.
Re:New Machine Learning Gems for Ruby
by beakerbreaker on Sunday June 20, 2021 @10:19AM
(#27570256)
There is some exciting development on that front by building on XLA.