Posts Tagged ‘Python’
Here is a small FAQ about how to become a programmer in Python and making progress. Do not expect this FAQ to be completely logical. Python’s name comes from Monty Python’s Flying Circus. So you have to experience the language to appreciate it… before to think ;p
Python is simple, so becoming a Python programmer is simple too!
How to learn to program in Python?
The answer is simple! Go to the address http://www.python.org/doc/ and click on the Tutorial link.
Once you have done with the tutorial, you will not be a strong Python programmer. In fact, at the end, you will be able to put most of your ideas into a Python script. It helps if you have experienced programming with another language and if you have some knowledge in object-oriented programming (OOP) — the last is optional. But, above all, it is necessary to have a sufficient open mind.
How to be a better Python programmer?
The answer is simple! Practice Python and read the source code of the files in the Python standard library ($PYTHONPATH/Lib).
Do not fear that kind of code, it will not bite you! By doing this, you will learn some patterns and some idioms used in Python. The bulk of the source code in the standard library is sufficiently clear.
How to become a strong Python programmer?
The answer is simple! Read the PEPs (Python Enhancement Proposals) starting from this one http://www.python.org/dev/peps/ and use google.
Here the goal is to explore what is unknown by most of the programmer or by other language. Do you know what is a generator or a decorator? Can the list comprehension make my life as a developer better? And what about the database API? The answers are in the PEPs and google.
For example, to learn more about Python’s decorators, take a look at http://www.python.org/dev/peps/pep-0318/.
Is this enough?
The answer is simple! Absolutely not!
All the answers here should be considered as starting points. After that, there are many things to explore. But, you have to do the same thing you would do with another language to improve your skill: explore forums, listen to conferences, answer to questions, and contribute.
To Infinity And Beyond
$ python -c "import this" The Zen of Python, by Tim Peters Beautiful is better than ugly. Explicit is better than implicit. Simple is better than complex. Complex is better than complicated. Flat is better than nested. Sparse is better than dense. Readability counts. Special cases aren't special enough to break the rules. Although practicality beats purity. Errors should never pass silently. Unless explicitly silenced. In the face of ambiguity, refuse the temptation to guess. There should be one-- and preferably only one --obvious way to do it. Although that way may not be obvious at first unless you're Dutch. Now is better than never. Although never is often better than *right* now. If the implementation is hard to explain, it's a bad idea. If the implementation is easy to explain, it may be a good idea. Namespaces are one honking great idea -- let's do more of those!