Python Logo

If you don’t know any computer languages, I recommend starting with Python. It is cleanly designed, well documented, and relatively kind to beginners. Despite being a good first language, it is not just a toy; it is very powerful and flexible and well suited for large projects.

From How To Become A Hacker, by Eric S. Raymond, author of The Cathedral and the Bazaar and Why Python?

Why Python On Windows XP?

Python is an interpreted programming language. On Windows, amateurs (like me) use it as a scripting language. If you’ve dabbled in creating macros in Microsoft Word or experimented with various hot-key or keyboard macro programs, you have a mere inkling of how useful a scripting language can be. Learning to program in a REAL computer language, like Python, enables you to make small, fast, accurate, customized scripts and “applets” that do exactly what you want them to do on your computer.

A simple example will suffice. Isn’t Google Desktop Search handy? Yes. Sometimes. But how often does your search produce “179 emails, 468 files, 273 Web History.” Instead of loading huge indexing programs to find a single file, wouldn’t it be nice if you could type a few commands into your Python interpreter and tell your computer to search only Microsoft Word documents for the word “Bartleby” in the “Novels” folder?

Once you know Python, you can do just that, and you can save your little program in a script file that will allow you to run it again whenever you want. The next time you might tell your program to search only plain text documents for the word “gloaming” in the “My Documents” folder. Just one trivial example.

Learning a real programming language takes too much time, right? Yes! And if the prospect of spending time learning a new language makes you uneasy, please leave now. Learning any language takes time and effort. Don’t learn French, unless you enjoy it, are curious about French culture, and perhaps would like to travel to France. If you are reading this, you are at least curious about computer programming. My advice is to try it. If you don’t like it. Quit!

Before you go, consider the time you have invested over the years learning to “speak” the language of individual programs, like Microsoft Word. When you learn how to make Word macros, or how to program keyboard macro software, you have expended a lot of time and effort learning the language of a single program on a single platform (Windows). When you learn a language like Python, you learn to control almost any program on any platform (Windows, Linux, Mac OS X), because Python runs on all of these and comes preinstalled on Mac OS X and Linux. When you learn Python, you also learn computer science and at least the basics of how to program computers.

Some of the best programming tutorials on the Web use Python to teach curious newcomers how to program. Why? Python is easy to learn, but very powerful. It’s checkers if you just want to play around, and it’s Grand Master chess if you decide you’re in for the long haul. Google uses Python. NASA uses Python. You can use Python, too.

If you want to know more about Python, read about it at Wikipedia, or poke around the Python.org site. Don’t be put off by the high-level geek jargon. If you are new to programming, your best bet is the BeginnersGuide/NonProgrammers page. If you have questions, visit the Python.org General Python FAQ page. Later, when you get in over your head and want to ask questions or seek advice, go to the Python Users Group at Google Groups.

Above all, remember that programming in Python should be FUN. The guy who wrote Python (Guido van Rossum) now works at Google. He named Python after the Monty Python comedy troupe, not the snake. Python programming tutorials borrow from Monty Python whenever possible. For instance, here is a link to the famous Monty Python Dead Parrot sketch on YouTube, and here is a link to Guido van Rossum’s Python tutorial illustrating the use of keyword arguments in functions with lines from the Dead Parrot Sketch.

If you are a Windows XP user and want to install Python on your computer, visit: Python on Win XP: Seven Minutes To “Hello World”.

If you want to read a good Python book while you are learning, try one of these two written for beginners:

After you acquire basic knowledge in Python, you can move onto some other great books:

  • The Python Cookbook, 2nd Ed., by Alex Martelli, et. al, which provides “recipes” for common tasks you might like to accomplish using Python on your computer. For many people, this is the best way to learn code, by studying examples contained in programs that do useful work.
  • Learning Python, 2nd Ed., by Mark Lutz, commonly considered the most thorough introduction to the language for beginners.
  • Python: Essential Reference, 3rd Ed., by David M. Beazley. This is the newest of the Python books and probably the best all-around Python book, but newbies may find it overly terse. Beazley wastes no words and has a tight, crisp writing style. If you are already familiar with basic programming concepts, but are new to Python, Beazley is your man.

Good luck and have fun!

Richard Dooling