Isn’t it ironic how things pan out when you really get interested and involved in development as a whole?
I was as happy and content as a C# developer can be. Then a couple of months ago a fellow colleague, Gareth Stephenson, introduced me to the Ruby and Ruby on Rails world. Somehow I could not get used to the Ruby style of doing things and found it’s syntax kind of “sloppy”. Still like it though because the apparent sloppiness is probably the point of a dynamic language.
This then got me interested in the Linux environment and what the guys from the Mono project have been up to as far as porting and improving the .Net framework onto Linux. It was not until I came across Ubuntu’s free GIS offering named Quantum that I discovered Python and it’s application within the GIS community. I was like a kid with lots of new toys….whooopy!
So to get to the point of this blog, I am still a junior when it comes to the “Snake” -Python that is, and I am going to share everything that I learn as I learn it with whoever want to do the same.
For a start go and get the latest version of Python from The Python HQ. You will most probably find everything there as far as upgrades, PEPS and happenings in the Python community.
Once you installed the Python command line, type “import this” and Enter. This will spit the following out:
- 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!
Cool hey? Tim Peters you beauty!!!
Something to contemplate till next time.