Why We Choose Python
sixfeetup.com
sixfeetup.com
> Python is robust
This paragraph does not feature a word about robustness. There are mentions of speed and scalability and some sort of benchmark showing a case where Python is faster than Ruby or PHP. Conclusion: "It's also very fast".
The rest is less terrible but does not mention any of Python's shortcomings.
I love Python, but let's not make this a True Scotsman fallacy.
[Disclaimer: I love Python and if anything, it's more popular than TIOBE indicates. This comment expresses an opinion about TIOBE, not Python]
Ratings
The ratings are calculated by counting hits of the most
popular search engines. The search query that is used is
+"<language> programming"
I wonder why BASIC is so popular :)Also, the community practices for coding style are so strong in Python that I can open up nearly any piece of code on the internet and have no problems reading it no matter how junior or senior the person was who wrote it. This is a big win for maintainability and one of the main reasons why I prefer Python over Ruby or Perl.
I am not talking about finding one developer. I am talking about finding one, scaling to five and then beyond that.
Also, with more and more colleges switching to Python as their Computer Science major's language of choice, finding a team of competent Pythonistas is getting easier. I would think that it helps tremendously to be able to hire remote workers (especially since a town of 4,000 probably won't have more than a couple of people who are Plone experts, at most!)
Also some of the big local companies like to use Python including Angie's List.
This is changing, which is good.
Of course thats a bit harder now, I would look for a functional language on there these days.
It is frustrating, because Ruby and Java are the standards where I work, and Clojure/Haskell are my favorite new toys. But I refuse to program in Java, and none of the others have ecosystems anywhere near as awesome as Python.
It is a shame, because Clojure is a better language.
variable = somefunction(inputParameter)
where variable did not exist before leaves me having to look up the documentation of somefunction to know what kind of object it is returning.
Try this variant:
variable = somefunction(inputParameter)
# the next line is a temporary debug statement
print "variable has the following attributes:", dir(variable)
Or this one: variable = somefunction(inputParameter)
help(variable) # temporary debugging statement
Or this one: help(somefunction)
Or even this: variable = somefunction(inputParameter)
print "the type is", type(variable) # temporary debugging statement
A lot of API's use built-in objects, so quite often you don't even need anything more complicated than: variable = somefunction(inputParameter)
print "variable is", variable
Using a Python-aware IDE like Eclipse PyDev might help too, but it's been a while since I've personally used it so I can't say off the top of my head what feature you want. Honestly, Python is so easy to use, you don't really need an IDE at all (of course this is just my opinion on something that's purely a matter of personal taste). def somefunction(inputParameter):
'''
inputParameter: List of seven positive integers
representing a poker hand
Returns: A positive integer used to score that hand
relative to all other possible hands, better hands
receive higher scores.
'''Sometimes that is frustating. I suffered a lot until I understood the Django's forms API. But this feature is worth the cost.
The Python community allied with the good programming habits (aka PEP 8) really does the difference.
Even better I can look at someone else's code and if they've bothered to follow PEP 8 I am straight in, understanding the code and not their formatting. It removed a cognitive load that in C++ just kills me.
It's bloody great.
http://www.sixfeetup.com/blog/why-pep8-for-plone-development
But I don't see any real valid reasons in the article to convince people. Do I have a valid reason? Probably not, every project has their own reason to use a specific language.
One valid reason to choose Python instead of PHP: Encoding. Never had any big problems in Python and a lot in PHP. Oh and multithreading.
Encoding is rarely a problem in PHP. Use UTF-8 everywhere, make sure every part of the system uses it (the database server, the database client in PHP, the web pages, etc.). If you're going to work with e.g. Japanese characters, use http://www.php.net/manual/en/mbstring.overload.php
http://web.archive.org/web/20070202012909/http://www.amk.ca/...
http://www.rittau.org/python/warts
in fact I would love a warts wiki for frameworks, libraries and more. Python or not. Its important to have these debates out loud.
Note: Yes, I write source code on paper. Alot.
Hahahaha. I love Python and loathe PHP but this is just ridiculous.
I love Python but looking at the long term trends on TIOBE I am not sure I'd agree with the above statement http://www.tiobe.com/content/paperinfo/tpci/images/tpci_tren...