Disclaimer: I don't hate Python. I'm studying it over at Exercism. The opinions of the writer and commentators of the quoted article are their own.
I recently stumbled over a, new to me, news aggregator called TechURLs. It's part of a larger stable of aggregators, including MathURLs and likely many others.
It was on TechURLs that I discovered an opinion-piece entitled Python is not a great programming language.
So I'm wondering, as I do, does Python have any cons (in the pros and cons sense)? It seems fairly ubiquitous, appearing in all sorts of places, so the pros must be fairly compelling. But are there situations where it's really not the best, and if so, why?
Top comments (1)
The piece titled "Python is not a great programming language." is a super subjective opinion about the syntax of the language itself. The author thinks that list comprehensions is a "con" in python, while in my opinion, list comprehensions are one of the most powerful and readable tools of any language.
In my opinion these are the most outstanding downsides of Python:
1) Poor concurrency (threads don't really run concurrently in python, multi-processes with shared memory also don't really work)
2) Poor latency in some cases: because the language is so dynamic. This is at odds with how little code you have to write compared to other languages.
3) Lack of static type safety. Not a downside per-se, because you could use type hints and static type checkers for safety, and because you are not required to specify types, you could write less, more expressive code.
Edit:
4) Because Python allows for so much freedom, it is very tempting to write really bad code. For large codebases and teams this could result in an ugly codebase that is really hard to onboard new developers to. For instance, adding type hints helps readability, but it requires discipline.