3 ms·
> There are many programmers out there using Python as if it was C, and that leads to slower than necessary code. I think it's because a lot of the Python (and
by discardorama 11y ago
> There are many programmers out there using Python as if it was C, and that leads to slower than necessary code.
I think it's because a lot of the Python (and I figure, other languages too) learning resources treat the learners the same way, whether you do not know any programming or are a 20-year veteran of C/C++.
I'd love to see resources which show the ideological way of doing things in a language. Take some of the most common tasks performed in other languages, and show how they're mapped properly to constructs in Python.
In this particular instance: I'm guessing the author could have used pure Python alone to get a decent speedup, without reaching for NumPy.