Why Python is My Go-To Language
I'm surprised at how many developers I meet who aren't aware of Python's capabilities. It does way more than many developers realize, and it just keeps getting better.
Below are reasons why Python is my programming language of choice.
Python runs on pretty much anything; Windows, Linux, Unix, OSX, and more
Want people to run your code without the Python interpreter? No problem.
If you're on Windows, you can use py2exe to create an executable file
for distribution (so your users don't have to install Python). You can
also use cxFreeze
to create executables for other platforms (it works
great on Windows too, but you can't just distribute one executable file; the executable file must be accompanied by other files).
Want to build a desktop application, or a multi-threaded HTTP server? There are tons of frameworks for doing these types of things.
For example, there's CherryPy
, a production-ready, multi-threaded web server and web framework. It's simple and quick to get a website live; you just run your Python code and you've got a web server running and your site is up.
Or, try building a desktop application with wxPython
, a cross-platform GUI library based on wxWidgets.
Python's standard library (that ships with Python) includes:
Command-line parsing (optparse - more than just an argv array)
A GUI toolkit (tkinter)
and a ton more.
Want to build your own version of Python, or bundle pieces of it, and sell it? You can. Python's license
is very commercial-friendly.
If you'd like to make contributions to the language, or ever need to make changes to the interpreter, the source is freely available.
Need to access a C++ library, or want to speed things up? There are numerous ways to call into C++ code. As an example, SWIG
is a great way to get bindings written to connect your Python code to C++.
There are really good IDEs available for Python.PyCharm
is by far my favorite. It is a commercial application but there is a community version that is free (Apache 2 licensed) and packed with features.
My next choice for Python IDE is PyDev
(Eclipse based, open source).
Want to make your Python code run faster? There are numerous ways to do this (besides writing C++ code).Cython
, a superset of Python with type declarations that helps you compile your code into C code.PyPy
, an interpeter that helps speed up execution using Just-In-Time compilation.
Want do you think? Feel free to comment below, or find me on Twitter @jasonprogrammer