View Single Post
Old 12-27-2022, 04:08 AM   #201
jbjb
Somewhat clueless
jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.jbjb ought to be getting tired of karma fortunes by now.
 
Posts: 780
Karma: 10535853
Join Date: Nov 2008
Location: UK
Device: Kindle Oasis
Quote:
Originally Posted by Aleron Ives View Post
I don't think that's the right way to look at it. Python is designed to be a language that makes it easy to accomplish tasks. The price for that ease of use is decreased efficiency. A language like C is much more efficient, but it's also more difficult to use. It is perhaps an unavoidable tradeoff. Python provides a higher level of abstraction so that the programmer can tackle problems from a human perspective, but the code required to create that abstraction reduces efficiency. C forces you to think more like a computer in order to accomplish anything, and having little abstraction is efficient, but it can also be obnoxious. You have to pick your poison depending on what task you're trying to accomplish.
I don't really disagree with any of that, but it's not the point I was making.

I'm not saying that Python is a bad language - it certainly has many valid use cases and indeed I use it a lot.

My beef isn't with Python itself, it's with programmers who only know Python, or who have spent too much time with Python before using other languages. There's a style of programming that Python encourages that leads to inefficiency (particularly in terms of memory use) that is over and above the inefficiencies in the language itself, and that earlier exposure to other languages can teach programmers to avoid in their Python programs.

Learning C and/or C++ will make a better Python programmer (particularly if done before the Pythonic styles become too firmly embedded) - that's my point.

It's also true that learning Python will make a better C++ programmer - it works both ways.

I guess my real point is that a good programmer should know multiple languages, not just to be able to write those languages, but also because the learning and mental toolkit developed from each language improves programming in all the others.

Too many graduates emerge from Computer Science degrees only really knowing one language. These days that's mostly Python (a few years ago it would often be Java), which is why Python gets the sharp end of my irritation - it's not the fault of the language, my concern is more with the state of CS teaching in universities.
jbjb is offline   Reply With Quote