Learning Python, Fourth Edition
O'Reilly Media, 2010
1,216 pp., $54.99
I have been a Python programming fan for many years. I was introduced to the language during a time when I was quickly becoming enamored with the first release of Borland's Delphi. After boasting to another developer about how Delphi was vastly superior to the version of Microsoft's Visual Basic at that time, this insightful person suggested I take a look at this relatively new dynamic language named after the Monty Python comedy troupe.
I put his suggestion off for a few weeks while I continued whipping up GUI goodness in various Delphi apps I was writing. Then a server-side text processing need arose, offering the ideal opportunity to give this snake-mascot language a chance to show me what made it so special. At the time, there was no Google, so I obtained most of what I needed from newsgroups and the meager Python 1.x documentation available at that time. Still, I was impressed with the rapid development time, the clear (and forcefully formatted) syntax and overall concise engineering nature of the language. It wasn't until 1999 when I read the first edition of Mark Lutz's Learning Python that I understood the reasoning behind much of the language's intentions and design decisions. Indeed, after Learning Python, I felt as though I had truly taken the time to deeply learn the language rather than call upon bits and pieces as I my projects demanded. More recently, Mark Lutz has written the fourth edition of Learning Python, a tome that weighs in at more than 1,150 pages.
The world of programming has changed considerably since the dot-com heydays and, perhaps not remarkably, the man who created Python (Guido van Rossum) is now at Google, and this powerful search engine company uses van Rossum's talents and his language for a portion of its secret sauce. For a company with the engineering calibre and collective IQ points of Google to commit to Python has much to say about the efficacy of the language itself.
So here we are in 2010 and the Python language is at a crossroads between its legacy 2.6 and below, and its new 3.x and higher. I agree with the book's author that those who are shackled by complex legacy Python programs to stick with the coding conventions of the pre-3.0 days.
Greenfield projects should almost always consider the 3.x codebase, with the upcoming 3.1 release being the most promising. It is with these suggestions and caveats that the author reminds readers of the difference between the two classifications and why the book has increased in size to accommodate explaining the differences and reasons behind the language's evolutionary changes.
For the uninitiated, especially those new Django web developers who are ready to go beyond the browser, Learning Python is the bible of Python education. Reading this book while practicing the code at a terminal and taking the quizzes at the end of each chapter along the way will elevate your depth of knowledge and appreciation for this workhorse language. Even for a seasoned Python veteran like myself, the book took over two months to read cover to cover. While much of the material is replicated from earlier editions, there are enough insertions of new insights and syntax call-outs that made revisiting this book like seeing a favorite city that has continued to undergo explosive construction and expansion.
Five new chapters filling an additional 200+ pages touch on more advanced topics such as Unicode, managed attributes, decorators and metaclasses. Receiving this more comprehensive instruction helped me better obtain a crystal clear understanding of these constructs and the recommended approaches for their use. So even after 10+ years of reading Mark's evolutionary work, he still has precious nuggets of information worthy of the book's cover price. Naturally for those who are new to the language, all the basics are covered in great detail in the books eight parts: Getting Started, Types and Operations, Statements and Syntax, Functions, Modules, Classes and OOP, Exceptions and Tools and, the bulk of the new material, Advanced Topics. Two appendixes on Installation/Configuration and the solutions to the end-chapter quizzes round out this city phonebook-sized educational experience.
Overall, I give Learning Python my strong recommendation to anyone seeking the most detailed introduction to the language and who has the patience to commit to the multi-week effort of grok'ing the material the author has condensed into this culmination of his years of writing and teaching the subject. While other Python tutorial books do an adequate job of getting readers up to speed quickly, few can touch the depth and calm, steady progression of deeper understanding by example and comfortably clear explanations by an author who has devoted the last 10+ years of his life to the art of teaching Python to the world.