Hacker News new | ask | show | jobs
by junoper 1622 days ago
Python, I think, has n number of ways of doing the same thing while Ruby's everything is object approach forces you down a single approach. So while reading ruby code, you usually don't have to shift your mental model from OOP to procedural/list comprehension etc.

If Ruby gets a good machine learning library on par with something like Pytorch, I am sure many folks will shift to it and we might see new DSL emerge.

2 comments

Which is ironic, given that "There should be one-- and preferably only one --obvious way to do it" is in PEP 20.
I agree. This has always driven me crazy. Python is supposed to be “there’s one way to do it” but I find it quite inconsistent!
The vast majority of Python code that I have had to interact with professionally seems to ignore the fact that PEP even exists.
How I wish that was a possibility. Unfortunately Python's dominance of ML and AI is a fait accompli. If anything is going to replace Python in this domain it won't be another scripting language with similar performance.