rank trend

Learning Python, 3rd Edition

by Mark Lutz
Released 2008-07-16
Read articles about Python
Buy it from AmazonNew for $26.39

127 Reviews

Sort by: Most Helpful ▲ Date Rating

5 stars Good even for experienced...

2004-01-26     100 of 103 found this review helpful

I was a programmer for 15+ years and used Perl for 8 or so of those years, so although I'm a newcomer to Python I'm definitely not a newcomer to programming or to scripting languages. When I ordered this book, I was worried that it might be too basic, but the more advanced O'Reilly Python books have not been updated to Python 2.2/2.3, so I ordered Learning Python anyhow.

And now that I've read it, I can highly recommend it even for experienced programmers. You will have to skim over basics in various chapters, but it's well-written and covers many topics, including 5-10 pages on 2.2's new-style classes, including static and class methods, instance slots, class properties, and __getattribute__.

It refers you to Python's documentation for the details of complex topics, but still gives you an idea of the concepts in play. For example, after a couple of paragraphs on instance slots, it says,

"... Slots are something of a break with Python's dynamic nature, which dictates that any name may be created by assignment. They also have additional constraints and implications that are far too complex for us to discuss here (e.g. some instances with slots may not have an attribute dictionary __dict__); see Python 2.2 release documents for details."

Which I think is a good compromise. They don't fill the book with details, but they don't simply wave their hands and give you no clue as to issues outside the scope of the book.

It is well-written and well-organized. It covers the core language well and gives a good taste for standard packages and many other tools including things like Pyrex and ctype.

(And you won't be disappointed with Python itself. A great language!)

5 stars Excellent introduction to Python

2000-02-24     96 of 101 found this review helpful

Together with "Perl: the programmer's companion", by Nigel Chapman, this is one of the best introductory book I ever read. If you already know "Programming Python", the previous book of Mark Lutz on Python, and are concerned about the possibility that this book was just another messy collection of concepts and tips, relax: this is a completely different object. "learning Python" is a well-designed, well-written and concise book. It gives you all you need to write system administration utilities, Internet-related programs and other small applications. (Should you need a book on TKinter, the standard GUI module of Python, buy "Python and TKinter programming", by John Grayson, Manning publisher).

Consider to buy this book because:

- It is clear and well written. No struggles to understand the basic concepts and having the first programs running.

- It is well-designed and well-structured. You can find the info you need in a snap.

- You get a real understanding of Python, not only a description of its nice features.

- It is concise. In a day or two you will be coding in Python.

- It is a very good guide to keep on your desk. It is the missing part of the online documentation.

- In describes how to perform the most common task with Python. You will not have to reinvent any wheel.

- It describes a few important modules of Python: JPython, TKinter and COM. You can get a feeling of what you can do with Python (but, to go further, you will have to read the online documentation and perform a few experiments by yourself).

Python is a very smart language and deserved a better book than "Programming Python". This is that book.

2 stars Fair introduction to Python for an experienced programmer

1999-10-05     37 of 45 found this review helpful

First off I would like to make a distinction between the Python programming language and this particular introduction to it. Python is a great language and you will enjoy programming in it. This is probably the source of excitement in reviews on this page. Because the book, unfortunately, has a number of flaws.

The tradition of O'Reilly Perl books has been not only to teach you the syntax of Perl, but also to introduce programming techniques and ideas how to make best use of the language features. This Python book scores zero on these points. It focuses on syntax exclusively and this makes it unsuitable for an absolute beginner. The examples are unimaginative. The authors show you how to write correct code for using "dictionaries", but not how to USE "dictionaries". A Perl book author would throw in a program that uses a "hash" to search for duplicate data entries (as they did).

Besides, the flow of the book is uneven. Functions and classes are discussed at length, but built-in data types and exceptions are looked at only briefly. All this is really unfortunate because there are not very many Python books on the market and it is a very good language.

Overall, I think, this book is best for experienced programmers who already know their CS, have to get up to speed with Python very quickly, have $30 to waste, and really love to own O'Reilly books. The rest might be better off by printing out the Python tutorial.

1 stars extremely disappointed

2003-01-17     28 of 30 found this review helpful

I bought this book because I originally bought the author's Programming Python book mistakenly thinking it would be similar to the Programming Perl book (which is a stellar book, where as the Python equivalent is more like a cookbook). It was immediately obvious that I was NOT going to learn Python from that book so I bought this one. Again, a mistake. It may be a fair overview of Python but it did not give me the tools I needed to be productive right away; and if it did have the information that I was looking for it was not obvious. Simple things like writing to standard error, file tests, executing separate programs and saving the output, parsing text, even how to force a script to bloody exit... basically common things people expect from a scripting language right away were given either little, weak, or *NO* obvious treatment. The appendix is no help either, I could not find most of these simple operations listed there under the usual key words. I'm sorry to say but this is the worst O'Reilly book I've come accross and (together with Programming Python) is a black mark on the series.

2 stars Not really useful

2006-01-03     26 of 26 found this review helpful

This book is not very good for actually learning Python. It also lacks a reference section and is excessively wordy.

Learning implies tutorials and a gentle progression from basic to advanced subjects; this book does neither. For example, in chapter 3, "How You Run Programs", it introduces modules and namespaces--fairly advanced concepts to read about before even the first "hello world" program! In chapter 4, as it describes the use of numbers and strings, it is already delving deep into the uses and implications of Python's objects.

With well over 500 pages, there should be plenty of room for a reference section, but there is none. There is no list of built-in classes and their methods.

The overall tone of the book is enthusiastic, touting Python's object-orientedness and other advantages. Unfortunately, it is excessively wordy and difficult to read. Cheerleading can be excused, but it is present on nearly every page and gets old quick.

In a book about programming or a programming language, one might want tutorials, reference, discussion of advanced topics, or code examples. This book provides none of these things. I do not recommend it.

5 stars Succinct Yet Thorough Intro To Python For Programmers

2001-06-19     24 of 28 found this review helpful

Mark Lutz and David Ascher deliver precisely the needed information to meet the objective stated on the cover of the O'Reilly text, "Learning Python" (Help for Programmers).

A succinct, yet thorough treatment of the Python programming language is presented in some 350-plus written pages that are well organized and facilitate the development of Python programs in a "Read and Code as You Go" fashion.

After spot reading the Chapters on "Getting Started", "Types And

Operators", "Basic Statements", "Functions", "Modules" and "Common Tasks In Python", I was coding and running my first text file I/O Python programs within the first half of a day. The authors concise presentation of the concepts definitely facilitated the "learning curve", which so often is an obstacle when learning a new programming language. The material was also indexed very well with clear index descriptions to easily determine what the topic was and where to find it.

What I found to be the strongest point of the book were the "Gotchas" sections, in which the authors discussed topics such as Python Language Constructs, Program Class Usage and Coding Practices to be aware of. I found the "Common Coding Gotchas" section at the end of Chapter 3 of great benefit in coding and debugging my first self-authored Python programs (As I learned, Python is definitely a language where you want to indent consistently, avoid the mixing of blank spaces with tabs and not forget the use of colons to denote decision logic). The application of these concepts alone were a great asset in reducing the "Learning Curve" for me.

The program examples provided reinforced the clear, concise concepts presented by the authors. The programs that I studied were suited to running in both a Linux environment (using Linux Python Version 1.5.2 for SuSE(tm) Linux 7.0 and Red Hat(tm) Linux 6.1) and MS Windows(tm) NT/98 (using Active State's Active Python(tm) Version 2.1).

Exercises presented at the end of the chapter were effective at reinforcing the programming concepts presented. With some supplemental tutorial material for non-programmers, this book could be used as an educational text for a Python programming class, particularly one geared for programmers with scripting language experience.

The authors did a good job of covering a number of topics important to application programmers. Object-oriented Constructs, Manipulation of String Objects, Operating System Module Use, GUI Programming Component Frameworks and Applications such as Tkinter and JPython are discussed to provide the reader a good exposure to the extent of the Python language implementation and its strenght as a robust, object-oriented scripting language.

The book is definitely an invaluable resource for providing the essential material necessary to construct your first Python programs, especially if you've had prior programming experience with other scripting languages, such as REXX, Javascript or Perl.

Definitely one of the best O'Reilly publications I've read to date. Kudos to Mr. Lutz and Mr. Ascher for their contribution to making the experience of "Learning Python" a fun and productive pursuit. Five Stars!

4 stars very good book for us noobs

2007-08-26     22 of 23 found this review helpful

I'm an experienced C/C++ developer and needed to pick up python in a hurry for work. I ended up buying several python books to make sure I had all my bases covered. I've come to appreciate this book a lot.

It does two things very well. First, it gives you a good overview of the language. You can read the book front to back and it has a nice progression. You'll certainly know the basics if you do that.

Second, and probably more importantly, for those of us too impatient to read a book cover-to-cover, it serves as an excellent reference for beginners. When I started out there were all the little noob things that I found myself constantly having to look up. Like "how do you specify a comment?" or "how do you structure and if-block?" or "how to you get a substring out of a string". Very basic questions like this that many python books don't bother with because apparently they are too basic.

If there is a weakness, it's just that this book is rather small and only covers the very basics. So reading this book alone will certainly not make you a mighty python programmer, or even give you enough info to probably write something interesting. But this book definitely deserves a place on your bookshelf if you are starting out and need the basics.

1 stars You'll love Python

2003-03-02     21 of 35 found this review helpful

I debated whether I should write seven pages, footnoted, indexed, and full of examples on why you should not buy this book and choose to seek another source for learning Python. But if you're the type who would actually make it through all that to get to the main point, you might actually LIKE "Learning Python". I'd rather save you, the save-able, from experiencing the same pain that I am going through right now. So here is my one-word review: "Excruciating". I hope this has been helpful. By the way, Python is fantastic and is ironically everything that this book is not.

5 stars Excellent introduction to Python

1999-11-23     18 of 22 found this review helpful

I believe this is an excellent book for learning Python. The author's style is flowing and smooth, the examples well-thought-out, and he makes it really easy to pick up Python. Compared to Programming Perl (the camel book) which is dense and heavily syntax-oriented making you feel like you're wading through syrup, this book was a pleasure to read.

Unreserved recommendation.

4 stars Thorough introduction but slow and not good for reference

2005-01-02     16 of 17 found this review helpful

I would never try to use this book as a reference. It was not designed and it's not good for that.

It was designed as your first book on Python, especially if this is your first programming language. As such, it gives you a really thorough and extensive introduction written by a renowed authority. The parts on functional programming, Python's OOP and modules lay the solid foundation for the future Python programmer. Beware though: compared to similar "foundation" books in other languages' realms, this one is slow-paced, limited in scope, wordy and even redundant at times.

If you already know a language like C++, Java or Perl, and especially if you've already written some Python code, then this book is not your best choice: it will seem terribly slow paced, tedious, bloated and of no value as a reference (which is what an experienced programmer like you really needs most of the time). In this case, you could use a short and freely available tutorial like Guido's, then a good reference book like Python in a Nutshell and maybe some more advanced books like Python Cookbook and Python 2.1 Bible (provided there will be a new edition).

As an intermediate or experienced programmer, you may still benefit from Lutz's "textbook". You may want to skim quickly through the first 3 Parts (which make 180 pages of beginner's stuff you've learned in highschool, decorated with the occasional gem toward the end of some chapters), then slow down a bit for the rest of the book and pay special attention to chapters 14, 17, 18, 21, 22, 23, and 27. This book has too many chapters for my taste, btw.

Part VIII, written by another authority (David Ascher), is a little too short and still bad for reference. In the next edition, I hope it will be expanded to a reasonable level of detail. I found the coverage of regular expressions particularly disappointing -- probably because they are covered by Mr Lutz's other book, Programming Python, which was supposed to be your second book. The exercises at the end of each Part are not the most interesting and useful I know of.

2 stars Disorganized, bloated book

2004-12-17     14 of 19 found this review helpful

I did not like this book. It is terribly organized. It is incomplete. Although it doesn't present wrong information, the way it is presented makes it seem inaccurate. Information on one same subject is scattered in many different chapters and never presented in one place. For that reason it is practically impossible to use as a reference or to quickly find a piece of info.

For example, while I was mid-way through the book, I wanted to quickly check what kind of comments Python supported. Does it support only one kind (line comments), or like C++ and Java has two kinds (line and block) ? So, I checked the contents - I was searching for a chapter called something like "lexical structure", or even "comments". No luck. (However, I did find a chapter called "Clicking Windows File Icons" ... - very useful! )
I didn't give up. Next step, check the index. "Comments" are mentioned three times in the book. The first time in the chapter "Basic Operations and Variables" (good choice!!!) - one kind of comment is described briefly in a paragraph with no relation to the rest of the chapter. Sadly, no answer to my question there.

The second time is in a chapter titled "Python Syntax Rules". Hmm, that makes more sense. Well, technically not, since comments are not part of the syntax, but let's not get technical ... Here it says that comments are ignored. Good to know. But how many kinds of comments are there ???

The third mention of comments is in the chapter "Documenting Pyhton Code". "Finally!", I say to myself and naively rush through the pages. Alas, no luck again. It says that "#" comments are a way to document code, but again it doesn't say if they are the only kind of comment, or if there are others.

By this time it is probably implied that there is no other kind of comments, since it is never never mentioned, however one SHOULD NOT have to guess about such things when reading a technical book.
I went ahead and checked the online Python documentation at http://www.python.org/doc/2.4/ref/ref.html . It took me 5 seconds to find "Lexical analysis", "Comments" and read what I needed. Why did I bother with the book ??

In defense of the book, I must say that it is not all bad. It does sucesssfully teach you to program in Python, even though it is strongly geared to inexperienced programmers (and thus annoying at places). However you absolutely need one more source of reference for Python, and if you have that, why buy this book ?

It is nothing like "The Java Programming Language", which in my mind is an example of an excellent language book and reference.

5 stars Good Beginner Language

1999-11-08     14 of 19 found this review helpful

I had no programming experience, and though I was worried at first to the many references to the C language it turned out to be an easy to follow book.

5 stars Best introductory book I have read to any computer language.

1999-06-07     14 of 17 found this review helpful

I was recently introduced to Python by the second author, David Ascher (who works at the same Institute as I do). I am really impressed by the power of Python and by the exceptional quality of the reference guides and this book in particular. As a former Professor of Computer Science at Harvard, I wish that all computer science books were written with this amount of clarity and humour. Everybody in my research lab is now learning Python from this book and my chief programmer is even more enthusiastic about it than I am. It has enabled him to write some image processing software in a few weeks that would have required months in other languages (and he knew nothing about Python two months ago). For myself, it has encouraged me to start programming again after a gap of many years. In summary, the Python language is extremely useful for image processing (and many other applications) and this book makes it very easy and enjoyable to learn.

5 stars Lutz & Ascher Do Python Justice

1999-05-04     14 of 16 found this review helpful

I can't get over how damn good these guys are. I've been toying with Python for almost a year, and been a heavy user since this past fall. It's been a godsend for both heinous class projects (go NumPy!) and side tinkerings of my own. The standard documentation is pretty good, and Lutz's Programming Python book (own that too) is also superb. I bought this new book sight unseen because I knew what to expect...and this book did not disappoint! I feel like buying this book for friends just to introduce them to the language. It's current, it's well written, and it is a wonderfully crafted introduction to Python. It's useful even to people who know the language already...it works well for me as a reference for those various things I forget here and there (to supplement Lutz's Python Pocket Reference -- another must have). Both of these authors have much to be proud of...thanks for this great addition to the Python world!

1 stars Major disappointment

2004-03-30     13 of 23 found this review helpful

Having programmed before (in dBase, COBOL, etc.) I expected to be able to follow a book that's intended for less-experienced programmers. Boy, was I mistaken.

This would probably be a fine book for someone who is migrating from C++, but I found many of their explanations needlessly cryptic. They use, in all of the examples, phrases from Monty Python - understandable, but totally useless for someone who wishes to relate functions to real-life application.

In short - if you've already mastered C, this book may help. If you have minimal or no programming experience, this book will show you how to perform functions, but will not explain what you'd want to use these functions for in application programming.

5 stars The best introductory book ever written

2000-10-09     13 of 19 found this review helpful

For all programming newbies that want to start with a real programming language, Python must their choice and "Learning Python" their first book on programming.

It provides a complete, concise introduction to Object-Oriented Programming (OOP) with Python and cleary explains how you can do almost everything with simple scripts!

It does not include any kind of reference at all - however this is not a drawback because it's not directly in the book's purpose - after all the standard Python distribution includes all the references you need.

So far, the languages mostly tought in schools are LOGO and stone-age distributions of BASIC (such as GWBASIC or QBASIC...). Even if you overlook the fact that they are way outdated, the most oblivious student can understand that even when these languages were created, they were all useless.

It's high time for this situation to change - as Python can be the first language a young person can learn and probably the only one it will ever need!

1 stars This book is awful. Use the online tutorial instead.

2007-07-27     12 of 15 found this review helpful

I am an experienced Perl and C programmer who wanted to try something new, and everyone raves about Python. The language itself is great -- but this book is awful. Here's the really short form of why I think so:
- The point of Python (or any programming language) is to do things, not to marvel at how cool the language is. Reading the book, you can't do anything other than toy programs until you're almost all the way through. That's 400+ pages of reading before you can do anything more interesting than basic operations.
- The book isn't concise -- quite the opposite. The authors marvel at the implementation details of the language at the very start -- which takes up many pages and isn't really relevant for the beginning python programmer.
I finally just went to the online python tutorial[...]it covered most of the same topics with a lot fewer words, and was less confusing to boot.
- The reason I buy books rather than just use online resources is to use the exercises as a method of forcing myself to learn the language in a structured fashion. The exercises in the book are trivially easy: they're not about thinking and understanding, but regurgitating what the book said. Because you're not doing any real work until the 400-page mark, you can't do anything really interesting in the exercises or on your own (if you're just reading the book).

I've read a lot of "Learning XXX" books. This is by far the worst.

My recommendation is to skip this book and go straight to the online tutorial. You'll save trees, money, and time.

3 stars Be Prepared If You Don't Know C/C++

2007-03-31     11 of 12 found this review helpful

I'm only about 100 pages into the book and I'm finding the constant references to C/C++ are getting very annoying. Just about every section refers to C, assuming you are intimately familiar with the language. "Just like in C", "same role as in C", "similar to X function in C", "unlike in C", "if you've used C", and on, and on. I suppose this would be a positive for someone coming to Python straight from C, but for the rest of us it can become irksome quickly.

3 stars Not for experienced programmers/scripters

2004-12-03     11 of 15 found this review helpful

If you're familiar and comfortable with other languages, you may find this book too long-winded. I think it could have slimmed down by 300 pages and been easier to follow and more useful for learning.

If you get annoyed by incessant references to Monty Python, you may find the various examples very distracting and irritating. ('Foo' is a nonsense word, and doesn't interfere with anything, but to constantly read 'spam' and 'eggs' gets really distracting.)

If you've never done scripting or programming, then the pace might be appropriate for you.

4 stars Better than Perl or Tcl or shell scripts

2004-01-12     11 of 33 found this review helpful

It gives a thorough description of how to use Python; which is indeed easy to learn if you already know another language. But when the authors say that not having to compile Python programs means that development time is speeded up, perhaps they are overstating. For most programmers who use compiled languages like C or C++, the biggest time is taken up in finding a method that solves a problem, coding it and subsequent debugging. These days, compilers on recent hardware are fast enough that link/compile times are simply not a bottleneck to development productivity. So it is a bit of a straw dummy that the authors put forth.

However, they are absolutely spot on when comparing this to Perl or Tcl. Perl is powerful, but its code looks like assembler. Perl gurus tend to shrug when you point this out, usually saying they understand it, with the not-so-implicit suggestion that if you can't, it is your fault. But this leads to a real maintenance problem and a barrier to entry to others. The cleaner Python syntax can show coding intent far clearer. Plus, and more importantly, the object oriented nature of Python lets you scale up to much larger programs. This has always been a problem with scripting languages, all the way back to the various unix shell scripts and DOS bat files. Often, the most those ever gave you in terms of modular capabilities was the equivalent of subroutines. Which is strictly procedural and not OO.

By the way, there is a small contradiction between the above claim that Python is more understandable than Perl and the claim that it has an advantage over C++ or Java because it is not as verbose as those. Typically, in increasing amount of source code, you have Perl -> Python -> (C++,Java). If you think that Python is more understandable than Perl, then by that same logic, we could conclude that C++ or Java is more understandable than Python.

So if you are using Perl or Tcl and want something better, Python is a good choice. A good upgrade path.

But if you are currently using C or C++, with maybe X for graphics, or Java, then I suggest you stay with those. All three languages, with their graphics, give you a far richer toolset. Python would be a retrograde choice.

2 stars Who is the target audience for this book?

2003-03-19     11 of 14 found this review helpful

I first purchased this book nearly two years ago, but I never got past the first few chapters.

I just picked this book up again, with the benefit of two years' experience programming in PHP and a little but of Java, and I realize why working through this book seemed like such slow going the first time around.

On the one hand, "Learning Python" is written with a lot of hand-holding for readers who may not have much programming experience at all with any other languages; the basic concepts of variables, statements, functions, data types and the like are all clearly explained, which is a good thing for someone just starting out.

On the other hand, there are also quite a few tips and bits of information about memory efficiency, or how certain elements of Python relate to their C underpinnings; things that a rank newbie probably won't understand, and probably doesn't need to know when they're just trying to learn the basics. These esoteric points are probably quite helpful/interesting for programmers coming from low level languages like C, but those programmers will be frustrated by the slow page of the sections covering basic mechanics.

So you've got a book that moves at a beginners' pace that's full of asides targeted towards experienced programmers; beginners will be confused and overwhelmed, and experienced coders will just get frustrated.

For what it's worth, I have the first edition of this book; I'm not sure how the second edition compares.

3 stars Not bad, but...

2000-08-12     11 of 14 found this review helpful

Can't really describe precisely what's wrong with this book. I've been programming, and picking up languages, for 25 years. This book didn't do anything for me... so I just started writing some code. At some point the light went on and Python was magically easy. Now, as I need to help some other people learn Python I'm looking back through the book and NOW it looks great - covers the key details, describes them well, warns you about pitfalls, etc. In short, everything I'd like to present as a trainer (and I know it grew out of the authors' experiences as trainers). But it didn't work at all for me as a newbie.

4 stars Good for reading and reference

2008-02-16     10 of 10 found this review helpful

I am pleased with this book. I read about half of the way through it and then decided to keep it close by as a reference guide. As a reading guide to 'Learning Python' it can get a little monotonous. This really isn't the author's fault, who shows a slight, persistent but non-distracting humor. I think some monotony is inherent in learning any programming language - 1) here is "Concept A," 2) here is how/why "Concept A" is implemented in general, 3) here are some particulars to keep in mind when implementing "Concept A", 4) here are the myriad of variable methods of implementation. This book covers mostly the 1 through 3 ideas above and leaves most of idea 4 for more advanced books or reference material. The author does a good job of managing content. There are places that give an overview and state that more detail is ahead, but the instance where a concept or implementation is initially mentioned and the degree to which it is described is adequate for the current context. The 'more detail' that eventually comes along then fits nicely into its own 'more detailed' context. In other words, I didn't feel like I had to jump forward 5 chapters to understand one aspect of the current chapter. What the book lacks, or blissfully does not include, is any lengthy code constructions (this can be good, bad, or mean nothing, depending on your learning style and requirements). "Python Programming, An Intro to Computer Science" is a bit more engaging but, ultimately, is not as verbose or specific where needed. I read through allot of books and actually see these two as worthy complements. I also use Python Programming, Python Essential Reference, Python in a Nutshell and Python Cookbook as supplemental references. Sometimes I am looking for an overview of a concept, just an example of code syntax, all the options available for implementing a construct, or how someone else approached a common problem, etc. Each book has its time and place. I tend to use Learning Python for the overview with some examples and consider it a useful companion to the online and other reference materials.

4 stars Its benefit depends on what you are looking for

2006-12-18     10 of 10 found this review helpful

I have been a Zope/Plone developer for over a year and that is also the total amount of time I have spent with Python. With a CompSci major and experience in languages like C, C++, and Java, Python was easy to pick up and is the most programmer-friendly programming language I have used. I learned Python mostly by reading the online, free book Dive Into Python and reading the open source code for Zope/Plone.

After a year of this, I knew Python pretty well (well, it took much less than a year) including best practices, but I felt that I may be missing the full potential of Python, because I only learned it in the context of Zope/Plone APIs and my needs for developing in that framework.

I picked up this book hoping to recover the basics, understand the behind-the-scenes technical aspects of what Python is actually doing, and to make sure I hadn't missed anything along the way.

For this purpose, I think this book works very well. The writers explain what is really happening behind the scenes (mostly in C), a handful of gotchas, and really helped me understood what Python was really doing and why. If this is what you are looking for, this is a great book to have.

However, if I did not already know Python, I think this book would have set me off track a bit. The writers spend a lot of time on what are really trivial concerns for beginners, and they hardly ever discuss best practices. In their effort to cover all the bases, such as while loops, they sometimes show something that is not a best practice in Python (you hardly ever use while loops in python). Important topics like classes and OOP aren't covered until late in the book. If you are new to Python, I highly recommend checking out Dive Into Python instead. They will get you developing as a Python programmer, instead of a C programmer that happens to be using Python (ie, using list comprehension instead of while loops, etc.).

5 stars Probably the best Python textbook

2004-01-28     10 of 12 found this review helpful

After a brief encounter with the on-line documentation from Python community, I decided to learn this powerful language with the help of Python library from O'Reilly. I started with a "Python in a Nutshell" which is a good reference guide for experienced (Python) programmers, however it's too heavy for the Python newbie like me. Since, I'm not a professional, full-time programmer, I knew that I needed something more comprehensible, so I waited for the second edition of the "Learning Python" to be published. At the end, the wait paid off.
This book is excellent study guide for any kind of programmers, from absolute beginners to veterans in other languages. The book clearly shows that the both authors are experienced teachers. Topics are presented in a clear fashion with plenty of code samples and useful exercises at the end of each part. This book should be read as a textbook in front of the terminal, trying out all examples as they're explained.
Now, I'm comfortably looking forward to read some more specific and advanced Python books. Highly recommended!

4 stars A good overview that can be used to learn Python

2000-10-26     10 of 15 found this review helpful

As someone who works with and trains people in many different programming languages and techniques, it is necessary for me to always keep an eye on new things. I had heard a great deal about the Python language and most comments were positive. Therefore, I read this book for the purpose of simply learning what the language had to offer rather than to actually learn how to program in it. I found the material to be well presented and informative, but certainly not for anyone with a limited programming background.
There are many references to what is done in C, which helped me, as I have an extensive background in the language. However, if you do not know C, then they are somewhat helpful filler at best, confusing chaff at the worst. The examples are in almost all cases very short, which makes them toys of limited use, but that is how learning a programming language is best done. It is possible to use this book to learn how to program in Python if you already know how to program in an object-oriented language. There are exercises at the end of each chapter and solutions to all are in an appendix. The exercises are at the level that they should be for beginners and the topics are standard learning material.
Since my goal was to simply learn something about the Python language, I extracted the desired information when I read it. If my goal would have been to learn how to program in Python, I could have also done that if I had read slower and did the exercises. It is a language with many interesting features and since it is also a scripting language, Python could be used for many things. No doubt I will have to learn it in the future and this book is where I will start.

2 stars Not worth the expense.

2005-12-13     9 of 14 found this review helpful

Programming books have two uses: to teach you and as a reference. This book does an adequate job of teaching, but I'd say that "How to Think Like a Computer Scientist" does better, and you can just look at it on the website. The index is lousy, which makes it hard to find things, and it doesn't cover enough material to make it useful. I wish I'd just bought two copies of Python in a Nutshell instead.

4 stars Good, improvable.

2002-02-10     9 of 10 found this review helpful

You can learn Python from this book. However, this is not one of those books which capture your attention, like, say, Kernighan's books, or even "Learning Perl". You have to fight against this book. This is mainly for the following reasons, IMHO:
1. Jargon is used too frequently. If you are not a hacker (in the good, original sense) you have to work against the language (not Python, English!), too. I had to reach for the "Hacker's Dictionary", now and then. For instance, the word "hook" is used in a technical sense without being explained.
2. Object is never defined. In the "official" tutorial, which is much shorter, a clear and concise definition is given. This is badly needed, for "object", in the python world, is different that in
C++, or smalltalk, world, where it is a class instance. In python it is the triple (type, address, value).
3. Phrases like "Classes are mostly just namespace" don't help the beginner who wants to know what distinguishes a concept from another. These abstractions are premature.
4. The too frequent use of Monthy Python terms like "spam" and
"eggs" is ridiculous, and makes the examples seem totally useless pieces of programming.

So, I think this book is perfect for one who is a personal programmer and wants to learn quickly what Python is all about. He will probably like the book for the very reasons I complain against it. The subtitle is correct: Help for Programmers.

Still, you'll learn the language. But with a fight!

4 stars Good starting point for pythoneers

2000-01-09     9 of 12 found this review helpful

This is a nice beginners textbook for Python which deals with many deatails, so that it is also valuable for people who already know Python. Still it is not reaching up to the highest branches of Python art. That would be the task of a massively revised second edition of the other Lutz book: "Programming Python". And it has to be said: Python is a great language!

2 stars Not for beginners...

2007-05-06     8 of 10 found this review helpful

This book bills itself as a book for beginners to programming but actually it's for experienced C programmers who are making the transition to Python. Someone with little coding experience will quickly get discouraged due to all the poorly explained terminology and constant references to C. Also, the pattern of the book is to give an introductory chapter on basic concepts then two or three chapters that get into extremely detailed explanations. At the end of one of those mind-numbing journeys through obscure details, the author will often will often say something like "But I would suggest you avoid doing this because..." Huh? Then why even bother to explain it? I can't believe Python is as dense and involved as this book makes it. If the authors would only spend as much time on simple, logical explanations as they do on explaining why Python is superior to every other programming language on the planet, this book might be useful.

5 stars This should be your first Python book!

2006-03-08     8 of 10 found this review helpful

This is simply a stellar introduction to the Python language, for both newcomers to programming and those who are already proficient in another language. I know there are several choices for 'beginning' type Python books, and you may be tempted to choose a different one because it is newer than this one, but please understand that you lose nothing by reading this book instead. It covers Python 2.3 (which is just short of the current 2.4), and there are only a couple of items not referred to (e.g. decorators and decimals). But you can easily read up on the latest features online. The benefits of this book far outweigh the fact that it was published a few years ago!

Here is the true advantage of Learning Python: the authors describe the language in complete detail from the ground up. They begin with how to use the interactive interpreter and IDLE, and then move on to built-in data types. Every single thing that could be considered a 'component' of the Python language gets its own chapter (numbers, strings, lists, etc.), and the larger components (functions, modules, classes, etc.) each get their own Part (which is further divided into chapters). In other words, they take plenty of time to describe everything you need to know about everything in the language. You won't finish learning the core language until well into the 400-range of pages.

Another intro Python book that I just began reading has already covered numbers, arithmetic operators, functions, modules, and a few other things, all by page 20! I won't name the book yet, because I'm not fairly deep enough in it yet. But this is certainly not good for a newcomer.

Don't even wonder about other books! Learning Python covers every aspect of the language in great detail, yet at the same time remains intelligent (e.g. it does not explain to you what variables in general are (hopefully you have a basic understanding of programming already), but it explains in great detail what variables *in Python* are). After you read this book, you will have an amazing foundation in Python.

4 stars Learning Python, Second Edition

2005-02-11     8 of 9 found this review helpful

Overall this is a well-written book. I highly recommend it to a person learning Python. The concepts are well explained with an economy of words. Some programming books are dry; whereas I found this book answering questions that a person learning Python (like me) has. The authors give a background on the language and do a good job discussing the language. The book is well laid out and has a decent amount of white space in the margins for notes.

The index was fairly good, but has room for improvement in having more entries in it so that key concepts can be zeroed in on quickly. One feature that would have helped would be to have longer program examples listed in the book. Solutions are provided in the back of the book. This comes in handy in case one gets stuck doing an exercise and/or provides insight to an alternative approach. If a person is going to learn Python, this book will definitely get them boot strapped quickly.

2 stars No help to me as a beginner

2001-10-03     8 of 13 found this review helpful

Though this book has often been recommended as an excellent source for beginning programmers, I didn't get much from it after the first chapter.

I found the writing excessively dry, the index substandard, the and the language very very opaque. The organization is also pretty haphazard. Quite often concepts are introduced briefly and off-handedly, but then dropped as "not quite ready" to be discussed, with no further reference given.

Most of the examples used to demonstrate basics are either trivial or very abstract. A set of well-thought-out, useful examples are missing from this book, and if they had been included, would have gone a long way towards showing a beginner how to use this language.

Generally, not up to O'Reilly standards.

3 stars Python deserves a better intro. than this

1999-12-24     8 of 11 found this review helpful

Python is a really interesting scripting language--about half way between Perl and Java. This book isn't hard to read, but it's not very interesting or entertaining. It covers a lot of the details of syntax, but doesn't really illustrate what the language is good for or how you would solve real world problems with it. If you like foo() examples, you'll love this book...

1 stars Learning Python?

1999-06-20     8 of 29 found this review helpful

I purchased the Mark Lutz's first book, Programming Python, and found it impossible to comprehend. So then I heard about a new book called learning Python, which was more of a tutorial-style book. I bought it immediately, eager to learn the language which I have heard so much about, and to my dissapointment, it seemed to be the same as Programming Python, only shorter. If you really want to learn a programming language, get Learning Perl by Randal Schwartz and Tom Christiansen. Good luck!

3 stars Presents the material, but way too much cheerleading.

2007-03-12     7 of 9 found this review helpful

This book does a good job of presenting the basics of the Python Language syntax, along with the built-in tookits that come with any Python Impelementation. However, an important thing to know when reading the language is also knowing what a particular language is good for and what it is not good for. It is at this task that _Learning_Python fails.

I understand that Mark Lutz and David Ascher are very enthusiastic of the language, but they lose credibility when, at every possible turn, they feel the need to take their dig at C/C++/Java. Some of these digs are misleading at best. For example, at one point the authors tout functions in Python as being superior to those in C++ because Python functions don't care about types, so any function works on types for which the statements in the function are all compatible, and makes a point about how this is not true in C++. This is misleading, because C++ (even at the time my copy of the book was printed) had introduced templates, which allows for much the same flexibility as Python functions. Do templates have their problems? Yes, but the book instead has us believe that this functionality does not exist at all in C++.

Also, at the beginning of the book is a section titled (in effect) "Why Use Python?". Instead of objectively listing the advantages and disadvantages of Python relative to the other languages, the advantages of Python are highly touted while the disadvantages of Python are deliberately minimized and brushed aside.

Contrast this behavior with Stroustrup's C++ book, where Stroustrup is careful to point out that C++ isn't right for everything, and that there are advantages to being well-versed in multiple languages, realizing that there is no need for one language to be *the* language. Overhyping Python does the reader a disservice -- either the reader will believe the authors, in which case the reader will try to use Python everywhere, or the reader will disbelieve the authors, at which point the author has no credibility and the reader will be less likely to take the author's points seriously.

5 stars A great place to start

2004-02-15     7 of 9 found this review helpful

This is an excellent place to start learning Python. The authors are very knowlegable and have obviously read and understood big chunks of the Python source code. Still, with all of that knowledge, they move at a good pace for learning (not too quickly or too slowly). I recommend this book as a great starting place for learning Python.

To pick nits, the authors (or perhaps the editors) need to learn the difference between affect (the verb) and effect (the noun). They use effect throughout, even when it is being used as a verb.

Also, I was somewhat disappointed with Tkinter, but this probably wasn't the fault of the authors. It's a big subject, and this book is more about teaching core concepts. With regard to big add-on libraries, such as Tkinter, this book is more about whetting your appetite. Knowing that such add-ons are there is half the battle, and the book accomplishes that, in addition to great coverage of core concepts.

I think my disappointment related to Tkinter had more to do with Python than the book. Python (the language) seems terrific for thin-client, browser-based development (CGIs), but not quite ready for prime time GUIs.

5 stars Excellent guide to learning python for beginners+

2004-01-17     7 of 8 found this review helpful

I have the 1st edition of this book published in 1999. the 2004 edition is improved in numerous ways and offers excellent examples, thorough explanations and a more gentle learning curve than any other programming book I have ever read.

I generally use Python to interface with linux/unix for scripting. I find it MUCH beter than perl for this. the minute I am done with a perl script, my understanding of it begins to deteriorate. Python is just the opposite. Full OOP makes code reuse a reality. clean, understandable syntax makes code I wrote 6 months ago easy to fire up and understand.

This is an excellent book. If you are interested in Python, get it.

5 stars A great intro to Python

2003-10-26     7 of 8 found this review helpful

Even after the recent introduction of dozen or so python books in the last few months, Learning Python still remains one of the best, if not the best, resources to start learning about Python. I owned this book for a period of a year and a half after my introduction to Python. During most of that time, I often referred back to it, and I can say that this book was indespensible during that early period of Python features experimentation.

This brings up a good point: the intended audience for this book are people who are just starting out with Python. If you are already familiar with Python, and have a year or so of experience under your belt, try Python in a Nutshell, Text Processing in Python and the excellent reference book: Python Essential Reference.

1 stars Simply dreadful

2002-10-03     7 of 10 found this review helpful

Having previously read several O'reilly Perl books I thought that learning Python from this text would be straight forward. Unfortunately this book has none of the helpful examples that the Perl books have and also dissappointing was the reluctance to write the code as you might using a text editor. Instead the authors seem to prefer to write code as it would be run from the interpreter on the commandline. This made it really hard to write any Python using the text editor. All in all a complete waste of money.

4 stars A Prized Possession

2001-03-02     7 of 10 found this review helpful

A really great book, but more so if you already have some knowledge of programming. If you are new to Python and can make a few things happen, but would like to have the basics discussed for you in a book to enjoy in bed, this may suit you just fine. My copy is a prized possession.

However, it is a book about learning the Python language itself. If you do not know anything at all about programming, consider *Learn to Program Using Python* by Alan Gauld.

5 stars Excellent for any beginner

1999-11-03     7 of 8 found this review helpful

This book is simply excellent for any beginner. I had no coding experience whatsoever and I could still learn a lot from this book and do things like scientific computing and even beginning a software project.

Of course, python is an easy language some would say. Nevertheless, I truly believe this is a must have for anyone who like me doesn't know about prgramming and wants to learn to use an easy language that could do a lot!

Kudos for the creator of the language and the authors of this book.

In no time, you will be ble to programm something useful.

5 stars Excellent (as long as you can already program)

1999-07-26     7 of 9 found this review helpful

I already knew C++ (and a little of other languages), so this was not a problem for me, but the book does assume that you already understand most basic programming concepts (and if you don't understand Object-Oriented programming you might have a little trouble at first, though they do give a good explanation). Of course, I can't really tell that part, just my impression. If you can do something as trivial as VB, I guess you'll be fine.

Other than that, this is an EXCELLENT book. I read though it in about 3 days, and it was very effective. For example, the day after I finished, I programmed a Python script for work that used COM, despite never having programmed anything in Windows before let alone used COM). It was that good.

And it doesn't have an OS-bias (despite that little bit on COM), which is good and really fits the language.

4 stars This topic will be covered later in the book

2008-08-03     6 of 6 found this review helpful

"This topic will be covered later in the book" is the phrase most often encountered in this book.
Funny - but even on page 593 (out of 635 where appendix begins) we still see "we'll meet such an example in Chapter 28".
It seems like if you take out all the phrases that promise you to explain things in the rest of the book, the book itself will thrink 1/4 of it's size. Why do I even need to be told that you will cover it later in the book - I ASSUME it will be covered if you mention it. If not - refer me to some other resource.
The phrase above is just an example of the writting-alota-words-to-fill-up-space style. The legacy seems to have been carried forward into programming python by the same author on which I am working now.
Unfortunately this seems to be the best book in it's class, and there really is nothing to compare it to (considering it covers python2.5).
Even though I was done with the book in few weeks, I would still have preferred a more concise and to-the-point text.

2 stars perhaps I'm spoiled, but I want something better

2008-03-14     6 of 8 found this review helpful

You can learn Python from Learning Python. But for a language that's attracted a lot of hype about its wonderful LISPy conceptual features (e.g., anonymous functions), this is a sadly pedestrian book in a lot of ways. Here are some complaints (I end with a request, so skip down if you must.)

1. There are way too many (i.e., more than five) screenshots of Windows programs, with accompanying instructions (thanks guys!) to find things in the "Start" folder. OK, that's snobbish, I guess I can just skip it. But it makes me feel uncool.

2. OOP is introduced very poorly, in fragmented ways, that do not aid deep understanding. I know LISP. I know C. I do not know OOP. If python is OOP, and in a cool, not bolted-on fashion, I want you to introduce and develop OOP concepts as we go along so I can get the hang on things. As it stands, things are introduced in a haphazard fashion for a long time -- what are __allthesethings__ I keep seeing? Even though the type handling explanation is done in a natural fashion. I think it's reasonable to expect that readers have understood *some* language before turning to Python, so you can throw us in the deep end as long as you're a good instructor.

3. The documentation features are introduced early, and very poorly. They just don't make intuitive sense as presented, and it's not helping that the examples are cutsey (a function that squares things is doc'd "Then we take your liver".) Actually, examples are all like this, kind of weird, arbitrary and dumb, which makes comprehension hard. Monty Python references, OK, fine, but at least have them make a little sense?

4. 2+3 are running problems with the book (another concept thrown up without explanation: functions, whose syntax is not explained until chapters later.)

5. Problems at the end of chapters are not particularly strong. There should be fewer of them, and they should be of greater complexity and challenge. That's a pedagogical opinion, of course, and reasonable people can disagree.

I think you can learn Python from this book. In fact, I'm sure of it given the comments here and the O'Reilly editorial team. But I'm on page 180, and I've come here to complain that while everyone is telling me that python is as slick as perl, with the conceptual elegance of an OOPy LISP, this book is doing an insanely poor job of proving the case.

Perhaps I've been spoiled by good books. But maybe someone can help this princess and recommend a better one for Python than this?

5 stars Pythonesque - a major contribution to learning programming with Python

2007-11-10     6 of 6 found this review helpful

I am really impressed by the 3rd edition of Mark Lutz's "Learning Python" book. It's a comprehensive introduction to the language. If you already know another programming language, you'll be able to jump in anywhere and get a quick working exposure to Python. If you are completely new to programming, the author starts slowly and moves at a steady, manageable pace. He provides all that you'll need to know in order to write and run programs.

I believe "Learning Python" would work great as a standard text book in college comp sci programs. It is a great exploration of the Python language and the best introduction I've seen covering how to actually build something more complicated in the real world than "hello world".

I'm a big fan of Ruby, but reading this new 3rd edition opens my eyes to what I've been missing by not doing more with Python. I've looked at other Python books in the past and none of them made Python really interesting. This book does.

I've been thinking about what language to teach someone totally new to programming - my kids, for instance, or college students just starting into programming . Python is a strong candidate and this book would be an ideal teaching aid.

One of the "pedagogical" things I like about Python (and Lutz's book) is how clearly you can see the influence and ancestry of C and C++. Lutz describes the steps that have been taken to improve Python into a more productive programming tool without giving up the power.This opens up an interesting line of discussion into the dynamic and evolutioary history of programming languages.

This is a big book. I'm only part way through the 600+ pages. You won't sit down and breeze through it in an afternoon. However, you'll quickly get well past "Hello World" and gain a good feeling for the language. I found it easy to skip ahead to some of the later chapters that interest me; they stand well on their own.

If you are curious about Python, this book will give you all the start-up skills you'll need.

2 stars Out of date now

2006-09-24     6 of 8 found this review helpful

Python has come a long way. This book does not instruct you on any of the newest features or capabilities.

If it was to be updated and written in a simpler to follow style...I would recommend it. Until then, I highly suggest you find another beginner book.

5 stars Perfect to get started

2003-11-12     6 of 7 found this review helpful

As an accountant and controller I had some programming experience as a user, but am no professional programmer. I was looking for an alternative to Visual Basic or C like dialects. I needed a language, to which I could add a database, with which I could process texts and numbers and preferrably spread sheets and above all, which would be simple and effective. I had tried Visual Basic, Delphi, Cache and others, but they all required too much time to start.
My objective was, to construct a database, that would read-in Excel spread sheets containing sales data of different countries every monty, store that data and compile comprehensive sales reports, that could be exported back to MS Excel.
Reading only this book, I was able to achieve this task within one month and was able to present a simple, but effective database, which allowed me to get the go-ahead with my project and earned me the respect of my boss.
I consider this book one of the best introductions I have seen for persons who have some basic knowledge about programming.

2 stars An average book at best

2002-10-21     6 of 8 found this review helpful

This book is a terribly lazy attempt at writing a Python tutorial.
Sure, you can read it from start to finish, and write yourself some working Python code. However, when you want to write something slightly different to what is covered in this book, you suddenly realise how incomplete this book is.

Eg, it covers the hasattr, getattr, setattr, and delattr built in functions, which is fine if you already know what attributes an object has, but in no way can I work out with this book how, or if it is even possible, to get a list of an object's existing attributes.

It is incredibly frustrating trying to learn Python from this book. I am writing this review because I came online to look for a better Python book. I was hoping to find something by the Wrox publishers, as their Beginning Java2 is excellent, but it looks like I am out of luck...

3 stars Geared towards first time programmers...

2000-06-12     6 of 9 found this review helpful

I would have preferred to give this book 3.5 start, but oh well. I think my opinion of this book would have been better if I was a member of its target audience. I picked it up ( ) about six months ago, and I only had the option of either it or Programming Python (also by Mark Lutz).

After getting through the first couple chapters I became a little restless because of the rate at which it progress's through the language. It falls into the same category as most other introductory level books, it presents both the language and programming as if never before seen by the reader.

I ended up getting getting Beazley's Python Reference, which I was quite happy with. But the one thing I do have to give Mr. Lutz credit for are the "Gotchas" section at the end of every chapter. I think Python is a terrific language, and it incredibly fun to program with, but there are a few things about it that are a little... mmm... odd, i guess. Lutz points them out whereas in a reference type manual they would be presented and a feature of the language rather than something that might trip you up.

There's also something to be said about his later chapters that try and present some of your options, as far as what you can do now that you know Python. A couple of other books I've read, i come away feeling.... "ok.... so what?" You spend all that time learning syntax and data structures, but there's no sampling of their application to anything.

If you've programmed very little (or not at all) get this book, Python is an excellent language to start out on. You don't have to mess around with variable types and pointers which can be a little frustrating in the beginning. Lutz's book is the best to start out with.

2 stars Get the Learning Perl book authors to write about Python

2008-06-21     5 of 7 found this review helpful

I've been wanting to learn Python for a while. Hearing that the 3rd edition of Learning Python had added "exercises", I ordered it. It was a mistake.

The book winds its way through each facet of the language one by one, making no attempt to integrate what you are supposed to be learning into a working, functional solid.

The exercises consist of simple parrot questions: "Name the four major components of the module search path." Even the major exercises are childish. After the chapter "Advanced Function Topics", write a function which prints its single argument. Then try passing it more than one argument, or no arguments, to see what happens!

The code examples are never more than five lines, usually initialization of a variable, then a toy operation on that variable, with in-line comments taking the place of actual demonstration. A particularly choice tidbit comes when the author demonstrates making user-defined classes adopt the iteration protocol. He gives as an example a class which iterates over a predefined series of square numbers, then finishes the section with a note to the effect that such a simple procedure should really be programmed using a list comprehension.

The author constantly urges the reader to try things in interactive mode, but he doesn't give much of an idea what to try. Of course the reader can make up exercises, or rewrite a old program, which is what I have resorted to, using this book as a reference manual, but that's hardly ideal. The author is an expert on Python, and I don't know anything yet; he should be directing my exploration of the language, not just handing me an atlas.

I give this book credit for completeness and for clarity of explanation. The author lays out language features and tells you how they operate in a way that is easy to grasp. What he fails to do is to get the reader coding and actually using all the bits of the language, so that actual work can be done. He notes that the creator of Python has a mathematical background, which accounts for the consistency of the language design. It may also account for the lack of practical instruction.

5 stars The Longest Short-way to Python

2008-04-23     5 of 5 found this review helpful

If you are a top-down learner this book is not for you. You can safely pick "Dive into Python".
However, if you are the bottom-up type, you will not regret. While the Python slogan promises "one way to do it", Mark Lutz will show you four, and explore every detail, like complex list comprehensions, closures and the diamond inheritance pattern. This is why you will wait 200 pages (exploring data types) until the introduction of the first Python statement, and 200 pages more for the first script.
But if you cross the details, you will get excellent understandings of the core Python logic, which will save you countless debugging hours in the future.
The OO part alone worth the entire book. It's going from the very basics of OO programming up to elementary design patterns and some advanced OO implementation issues in Python.
One last caution: although 600 pages, this book should be really read cover to cover. It's a true tutorial, which gradually develops the major concepts (sequences, assignments, references, objects, namespaces etc) from the ground up, with (midterm?) exercises. Give yourself a few hours to really learn, exercise your brain (and fully grasp 100 ways to silently override your variables with namespace mistakes). It's a great book.

3 stars teaches the language, but didn't convince me

2007-08-05     5 of 9 found this review helpful

I took some time off of work, and I really wanted to just relax and goof off. I'd won a Safari subscription in the Perl Foundation auction, and I wanted to put it to use. I added Learning Python to my bookshelf and had at it.

It's hard to separate Learning Python from learning Python, but I'll do what I can: I felt the writing was a bit dry. It didn't flow the way the Camel and Llama books did, and the attempts to inject humor were really awkward. For example, the author is excited to explain that Python is named after Monty Python, and that "foo" and "bar" are replaced with "spam" and "eggs." This sounds silly. In practice, it's distracting. My brain is used to reading code with foo and bar, and knows how to skip over them. "spam" and "eggs" makes it harder to read.

I guess this is trying to help me become familiar with Python culture, but it just bugged me.

Learning Python (the activity) made me realize that Python's most immediate failings were not the ones I'd heard bandied about. The whitespace thing has serious ramifications, but it wasn't keeping me from coding quickly. Instead, I found that the lambda syntax and statement/expression division in Python really, really got in the way.

The book didn't see this as a problem. It didn't even seem interested in acknowledging that some people thought it was a problem. It just said "lambdas are anonymous functions! Isn't that great?"* and moved on.

One of the best programming language books I've read was AppleScript: The Definitive Guide. The thing that made it a great book was the author's willingness to say, "Look, this is where the language is most insane and horrible." If the authors think that Python is always great, they should at least provide explanations of what pitfalls are avoided by the constraints that leave many outsiders grimacing.

In the end, I learned enough Python in a week to get through all the exercises and then refactor some goofy code I had inherited, confident of what I was doing. Considering that I was also relaxing, drinking beer, and playing video games through that whole week, I think the book lived up to its job.

It just didn't convince me to convert.

(* OK, I'm paraphrasing.)

4 stars A more appropriate title would have been "Learning to program using Python"

2007-05-15     5 of 6 found this review helpful

This book spends a LONG time going over some of the fundamental concepts of programming. Although it does include very thorough coverage of the Python language itself, it suffers in many places from not knowing who its target audience is. For example, there are many comparisons made between Python and Java (and even C); however, one would assume that anybody with even a passing familiarity with another language knows what a "variable" is or that you shouldn't type the "c:\python22> " part when following along with the examples. If this demeanor was limited to the first few chapters, it might not have bothered me, but throughout the book, the authors can't seem to figure out if they're talking to experienced programmers or people who need to be reminded where the "on switch" is. Chapter 19, for example, is 12 full pages of "the concepts of Object-Oriented programming".

However, it's worth slogging through page after page of intro to programming material to get to the discussions on some of Python's advanced features, which they do cover well. I had previously tried learning Python from the online tutorial and although I made some progress, I could tell I was missing some concepts. After reading this book, I feel like I understand the "Python philosophy" - a few days ago, I wrote "datetime.date( *[ int( x ) for x in token.split( '-' ) ] )" in a program - on purpose! (That creates a date object from a string in the form "2007-05-13", if you're curious).

If you've got a reasonable amount of programming experience, you might want to start with "Python in a Nutshell" instead, though; as well written as this book is, it could have been two-thirds as long and still contained all the information I needed from it.

2 stars Definitely not a reference book

2006-08-04     5 of 6 found this review helpful

This book isn't horrible, but it meanders all over the place. It often confuses the issue by using several concepts in one example. There are too many instances where a technique is shown but then explained several chapters later. Sometimes this is necessary in language books, but this book abuses the idea.
I usually judge a technical book by how well it can be used as a reference after you're finished reading it. This book is so scattered in organization that it really lacks any kind of usefulness. It promotes itself as a possible first book for programming in general, but there's no way a beginner would be able to follow the concepts in the way they're presented here.
On top of that, the writing style is choppy and often rambling.

4 stars Good introduction to Python, but don't buy it

2000-06-15     5 of 7 found this review helpful

Lutz's book is a pretty good coverage of the material, and is worthy of the O'Reilly name. However, you're even better off buying Harms & McDonald's "The Quick Python Book", published by Manning. It's less dry, more interesting, and just a better book.

4 stars Good Introduction, but limited

2000-04-17     5 of 7 found this review helpful

Learning Python is a good introduction, but if you are serious about learning and using python, you will need this book AND the larger Programming Python. An example of Learning Python's shortcomings is __str__ is not in the index for Learning Python (__str__ is the default way to print). It IS in the index for Programming Python. I have found using both books to have all the information I need.

Learning Python also has a pretty good introduction to object oriented programming and how it is implemented in Python. I haven't done a lot of OO programming and the description in Learning Python was readable and understandable.

Another thing I liked about Learning Pytyhon is that the end of each chapter had interactive examples you could run to reinforce the ideas presented in the chapter.

Clearly however, Learning Python is much better for beginners. And I must say, the index's of both book are pretty good.

5 stars The best introductory programming book I've read!

1999-10-06     5 of 7 found this review helpful

Excellent for beginning programmers. Very clear, light reading. Nice sense of humor. Even for advanced programmers (who are new to python), I recommend "Learning Python " instead of "Programming Python" because it is better organized and takes up less shelf space.

5 stars Beautifully organized; blows "Learning Perl" away

1999-07-14     5 of 7 found this review helpful

This is a miraculously good book. The writing is crystal-clear and the examples are well-chosen. Best of all, the book's organization is just about perfect.

I knew a smidgen of Python before starting this book, but "Learning Python" helped me understand and extend what I already knew. So much has clicked into place now.

I'm amazed that anyone would prefer "Learning Perl" to this book. Perhaps that reader was holding a grudge about "Programming Python" -- admittedly, not the best book in the world. :-) While the first edition of "Learning Perl" was nicely written, the second edition was an absolute mess. Schwartz and Christiansen tried to shoehorn too much new information into the old chapter organization, and the result was a nasty tangled mass of a book.

I wouldn't wish "Learning Perl" on anybody. Those Perl guys have a lot to learn from "Learning Python".

Want to learn a programming language? Start with "Learning Python"!

3 stars If books were measured by weight...

2008-10-27     4 of 5 found this review helpful

I just spent a few days going through this book and learned a lot. I've been working with PHP for years, but never did much complicated code. I studied Java about 8 years ago also and learned a lot about OOP from that. But never did any programming in Java. So it was all concept, no experience.

My reason for reading this book was to start using Python with Django. I wanted to learn Python first so I would understand the framework better.

This book covers in excruciating detail many of the finer qualities of just about everything you can imagine being in the language. I'm sure it doesn't cover everything the language can do. But somehow it spends 600 plus pages going over details that I wouldn't expect to find even if I was reading a 300 page book called "What I was thinking when I wrote this particular function on July 3rd 1991"

If something can be explained by 2 lines of example code and a three sentence paragraph about what's going on, the author does that -after 2 pages of explanation of how this code you are about to see might be a little like C, but it's a little different too, and how what you are going to learn is really powerful, and how some students might notice that the code is similar in structure to the code that you will see on page 400 later in the book.

If you think my review is way too verbose, read the book.

I give it 3 stars because it was in fact clear and well communicated information. It was just often hard to keep reading past all the unnecessary words to get to the useful content.

4 stars (3rd. ed.)Best way to learn Python

2008-06-26     4 of 4 found this review helpful

I used to say that there were several good books for learning Python. You just had to browse them and choose what works for you. Not anymore. This third edition, along with coverage of Python2.5, adds dark tabs for the exercises at the ends of most chapters, and I think that many people can now learn the language by just trying the exercises and comparing with the answers in the back. The sidebars are interesting. The tables are clear. The examples are instructive. The typesetting is well-chosen. Despite all the materials availabe free on the web, this book is worth the price.

4 stars Great introduction, but please buy 2nd edition

2005-10-04     4 of 5 found this review helpful

First things first: don't make the mistake of buying the first edition of this book. I bought it years ago and I was disappointed at how bad (and sometimes silly) the book was.

So this 2nd edition of Lutz's book is a great improvement. Some of the annoyances of the first edition have disappeared (e.g., the vacuous reference to "making things with stuff"), and the style and tone of presentation has been enhanced by making it less sparkling (which makes for a better book, believe me). It looks like the text has been written by different people, or, at least,that they received good editorial advice -- and followed
it.

I am glad that I can now recommend a GREAT book for learning the language.

5 stars Learning Python (Help for Programmers)

2002-10-23     4 of 5 found this review helpful

An EXCEPTIONAL introductory learning manual. My programming background is strictly mainframe Cobol (15 years). I have never coded in C, C++, OOP, or any other open-source language. I have found this book to be very easy to read, to understand, and to utilize in coding new applications. Even though Python is currently in release 2.2, this release 1.5 version of Learning Python is still 100% applicable.

If you are learning Python: YOU NEED THIS BOOK !!

5 stars Best Python Book To Start With

2002-07-18     4 of 7 found this review helpful

This is a wonderful introductory book to Python for people with a (small) background in programming. Significantly more readable than Programming Python, this volume succinctly relates what you need to know without bogging down in extended examples or tedious details. From here the online references take over or, like a true hacker, you can just start reading source code. Together with the upcoming Python Cookbook, this is all you need to buy to be productive in the best language you are ever likely to meet. Nice rat, too.

5 stars It worked for me

2000-10-28     4 of 6 found this review helpful

I think this book would be quite overwhelming to the compelete newbie to programming. It does assume that you have a programming background already, e.g. You will definitely not learn the principles of OO from this book, though you will learn the python constructs to support OO.

But if you have the background, I think this book serves its purpose well, I was writing non trivial programs within a few days of picking up this book. It gives a good feel of what can be acheived with Python and a good base before you tackle the more hardcore Programming Python.

5 stars Learn Python FAST for experienced programmers

2000-07-29     4 of 6 found this review helpful

I find this a great book for experienced programmers who have used other languages to get to know Python's unique features very well. The exercises at the end of each chapter with their abstract approach inculcate the concepts very well in the reader's mind as opposed to a 'learn by implementing "supposedly practical" stuff' approach which i believe only contributes to fluff in a book. This book could be aptly named Learn Python in X days where at the end of X days you would truly have a useful and in-depth knowledge of the language but this is also a testament to Python's simplicity and lack of idiosyncracies.

3 stars Slowly Paced

2008-07-23     3 of 3 found this review helpful

If your goal is to get up to speed quickly with Python this might not be the book for you. Especially if you already have programming experience then you are better off downloading the documentation from python.org. That documentation covers the same material but much more succinctly. For example, in the reference manual at python.org, the "while" statement is described in less than a dozen lines of text, while in "Learning Python" it drags on across multiple pages.

The advantage of "Learning Python" is this: (1) the author shares the style and idioms that experienced Python programmers would use; and (2) the author offers insight into the history and design of the language. This allows the reader to "taste" the language as well as learn it. But for a quick path to learning Python, I would recommend using the website's documentation.

3 stars I'm not impressed

2008-05-03     3 of 4 found this review helpful

I'm talking about the 3rd edition. It's the first book about Python that I read, so I can't make a comparison. It may be just the best first book out there, but I'm not impressed. The book reads like a draft, not a book in its 3rd edition. The author just keeps repeating himself on minor points in subsections back and forth. It's 700 pages long, but I wish it were half the length, after cutting needless elaboration and repetition. Perhaps the older editions are more concise. On the other hand, we readers may not have a choice.

5 stars Great Book For Experienced Programmers in Other Languages

2008-03-23     3 of 3 found this review helpful

After getting a review copy of Learning Python, 3rd edition, I had forgot how much really great material was in the book. If you are interested in learning about Python 2.6 and Python 3000, and have some experience with Programming in another language this is an excellent book.

This book is not a reference book like the excellent Python Essential Reference, but more of a example driven guide through features of the language. I would pick this book up even if you know Python, as it covers new language features that have not been documented in some books.

4 stars Much better than previous editions

2008-01-30     3 of 3 found this review helpful

I bought an earlier incarnation of this title a year or two ago and sent it back immediately. I was pretty wary of making the same mistake twice, but I'm happy to say that this 3rd edition is a significant improvement. I have a feeling it's a bit too obtuse for those who are new to programming in general, but if you've been at it for a while and simply need to pick up the various and less commonly used features of the language, it's a fine introductory text. It even highlights some of the upcoming changes in Python 3; not necessarily in any meaningful way, but it gives you enough information to future-proof your code as much as possible so as to make porting easier.

Unfortunately it is riddled with tragically unfunny Monty Python catchphrases you probably got tired of hearing 20 years ago. I can't wait for someone to create a language named "Rick James" or "What" so we can go on hearing Chappelle's Show quotes regurgitated ad nauseum.

4 stars Great

2006-08-12     3 of 3 found this review helpful

I am new to Python and really, really like this book. I have read it cover to cover twice. It is obviously biased in favour of Python, but goes out of its way to explain the "gotchas" and things that are not intuitive. All in all, a WAY above average computer book!

1 stars Kill your curiosity with this one

2006-07-24     3 of 14 found this review helpful

very bad book... do not use this book if youre starting programming or python. the first chapter itself will put you off completely. try instead beginning python by Magnus Lie Hetland. its simple practical and downright fun.

4 stars Not what I expected..

2004-08-31     3 of 4 found this review helpful

I bought this book to "learn python". What I didnt expect was to just learn how python compares to C and C++.

I did find the book helpful as a good reference that covers all python aspects that is quite ideal if you are an experienced programmer wanting to learn python as an additional language. For a beginner however, this is quite useless. Although I managed making it all the way through the book, I struggle writing any software past simple scripts or understanding other people's code.

Again, this doesnt make it a bad book, its quite brilliant infact. But beware it might not be as helpful as you like if you are not an experienced programmer in other languages.

Another note is, many built in modules in python come quite poorly documented (cough*curses*cough) and expect knowledge of the module in C/C++ requiring you to dive into complicated C/C++ documentation to make use of the module in python. So really, yes, python is easy, python saves time, but knowledge in C and/or C++ is recommended to make best use of it.

Hope this is helpful.

5 stars Worthwhile for new and experienced programmers

2003-12-18     3 of 4 found this review helpful

I own several books on Python, but found this one the best as an introduction. Interspaced throughout the chapters are many examples, which are indeed simple, possibly trivial (as other reviewers have complained), but in fact are purposely so in order to illustrate succinctly the specific points in the surrounding text. As a further and important learning tool are the excellent "test questions" at the end of each chapter. Solving these (answers in the back of the book) will train the fingers to code python and the mind to think python.
Overall the writing style is VERY accessible. After you learn python, you may prefer a very terse reference manual like Python in a Nutshell, but you learn the language best if you start with "Learning Python".
Luckily, the second edition will soon be here -- the reader is advised to wait for that.

4 stars Comprehensive but rather wordy

2008-12-16     2 of 2 found this review helpful

I have learned Python through this book, but to be honest, it wasn't very pleasant (although that's mostly because I was impatient). The book is comprehensive, but it's rather wordy. The two combined mean that it becomes one really huge book. Due to the length, it will take commitment to read through the whole thing, and in my opinion, for the first time learning, there's no need to go through this much detail. That said, I much prefer reading something easier like Byte of Python and use this book for supplement details.

Another issue about this book is its bottom-up approach. To some, it isn't an issue, but the bottom-up approach to learning isn't exactly everyone's thing.

I might have sound negative, but my score should indicate that I find this book an adequate buy. I personally like how the author mentions some common mistakes beginners make while going through certain language features, and I did learn a lot from this book even if it took commitment.

2 stars Somewhat disappointing

2008-10-25     2 of 4 found this review helpful

As a newcomer to Python, I find this book educational but somewhat inadequate for getting one's feet wet with a new programming language. Essentially all the sample code in the book is in the form of very short snippets run from the command line. There is almost nothing in the way of a full-blown sample Python program showing the reader what it's all supposed to look like in the end.

Python's strengths as a programming language are ostensibly its readability and ease of use, but you get no sense of that reading this book. All you get is bits and pieces that you have to glue together somehow. It's neither a complete technical manual nor a good introductory book for the novice programmer. The book is useful, but I would hope that there are better titles out there.

4 stars Good for beginners, the python docs can do equally good

2008-09-01     2 of 2 found this review helpful

Like my title suggests, if you have programming experience and you do not mind or have little trouble reading the Python documentation in a online fashion then its probably not absolutely necessary that you have to buy the book.

However, the author is very good in instilling the nature of Python programming and he's good at getting you to think about the concepts but this book is definitely not a cookbook. Last thing is that it doesn't concentrate on the GUI nor library usage etc as it's mission is simply to teach you about the core of Python

5 stars Learning Python - A Review

2008-07-29     2 of 2 found this review helpful

An excellent book for anyone new to both programming and the Python programming language.

If you want to learn how to program and are unsure where to begin, this book is definitely worth considering, both for it's concise, clear explanation of Python and programming concepts in general, and because the language Python is itself clear and concise.

Pros:
-Clear, concise
-Well written, decent pace
-Good intro for non-programmers
-Leads nicely into Programming Python and Python Cookbook
-Python itself is easy to learn, clear, and yet still powerful and cross-platform

Cons:
-Tends to drag in the beginning, spending too much time going over the details of the language instead of diving right into some useful code.
-NOT for programmers who have other language(s) under their belts. Consider Programming Python instead.

4 stars Python is easy - well...

2008-05-09     2 of 3 found this review helpful

Python has the reputation to be a language that is easy to learn. Well, why do you need a book more than 500 pages to only learn the language then? The answer is that even if you can learn the basics very fast, it has a lot of bells and whistles that can take time to master.

This book covers only the language not the libraries, but covers it very well. Highly recommended reading once you'll want to use the language to write something bigger than a script of 10 lines.

4 stars only because I would have expected some exposure to the standard libraries as well for a book called "Learning Python"

4 stars Great for experienced programmers

2007-06-17     2 of 3 found this review helpful

Learning Python is an efficient way to learn python if you are familiar with one or more other programming languages. The book does a nice job of comparing and contrasting python's qualities with those of other languages (C++ and Java in particular) and provides many concise examples that highlight specific features well. For me, Learning Python was a great way to get going with software development in python.

If you are fairly new to programming, however, this book probably isn't for you. The first few parts try to be a more general introduction to programming, but they aren't enough for those truly new to programming languages. As an experienced developer, you will likely skim through the first few parts of this book quickly.

It's also not an exhaustive reference manual, and with Python 2.5 now released the book is getting a bit dated. But the core language features have not changed much, and there is plenty of online material describing that changes since version 2.2/2.3 that this book is based on.

4 stars "Learning Python" is right

2007-06-05     2 of 2 found this review helpful

The title of this book says it all: "Learning Python" is a great book to read if you want to learn Python. Granted, Python is not the hardest language in the world to learn, and I'm not sure that this book goes into enough detail about Python's trickier features (generators, anonymous functions, etc.). Still, I was able to sit down, read this book, work through the examples, and walk away feeling like I really knew how to develop software in Python. Most learn-a-language books are too dense for you to learn the language from the book alone, but "Learning Python" definitely made it as easy as possible.

5 stars fast shipping

2007-05-06     2 of 21 found this review helpful

The shipping is very fast, and the condition of the book is cool!

3 stars Good as Python books go, I guess

2007-04-13     2 of 3 found this review helpful

I have been writing code, primarily in C and C++ since a long time ago. I picked this book up because I needed to pick Python up quickly, and this is the book my boss was reading.

The book does a good job of discussing the basic syntax of Python, and to some extent the design and working philosophy behind the very high level, dynamically typed language.

However, it is little more than that. The author is just not in the same league as other programming authors like Kernighan & Ritchie for C, Koenig, Myers, and Moo for C++, etc. There is little advice on how to use the language. I don't mean that in a syntactical/strictly usage sense, but from a computer science manner. For example, after reading this book, you would have no idea about how to implement a linked list in Python. In fact, you would not even know that it is not that great an idea to even want to implement a linked list in Python for most cases, and of course you would not know which cases are counterexamples of that. You would have no idea of how to create even slightly complex data structures like trees.

Of course, there is no requirement for and "introduce the language" type book to actually cover all that - but I those other authors are all that I have read in "language" books, so that is my comparison set. Sadly, I don't know of a good alternative to this book. "Beginning Python..." by Apress talks a little more these things, but that too is not organized nicely.

I guess there just aren't great Python authors around. You just pick the language and learn the tricks on your own.

4 stars Good introduction to Python especially if you are new to scripting

2006-12-12     2 of 3 found this review helpful

Python is a programming language created by Guido van Rossum in 1990. Python has a fully dynamic type system and uses automatic memory management. Therefore, it is thus similar to Perl, Ruby, Scheme, Smalltalk, and Tcl. Python was designed to be a highly readable language. It aims toward an uncluttered visual layout, uses English keywords frequently where other languages use punctuation, and has notably fewer syntactic constructions than many structured languages such as C, Perl, or Pascal. It is particularly popular among those programmers who are involved in bioinformatics. This book is a great introduction to the language.

The book uses the traditional bottom-up approach. After an opening part motivating the language and introducing the interpreter we progress, from data types, through statements, and up through functions, modules, classes and exceptions. Classes get 100 pages; other parts get about 50 pages each. A closing part covers common tasks, advanced uses, and Python resources. Appendices give details on installation and configuration, and provide solutions to all the exercises. The book is thorough and patient. Topics are discussed in detail and at a steady pace. Repetition is used more than cross-reference. This book would be very good for self-study, as you can easily plod along or just dip into subjects in which you have interest. The exercises are worthwhile and to the point, and the solutions are detailed.

Documentation and design issues are addressed early and often, and are clearly a central part of what is being taught in this book. The example code is of the highest quality. The book's faults are minor. Although the preface says PyUnit and doctest are in Chapter 11; they are not, being given just a paragraph each in the core language summary in Chapter 26.

The book is not comprehensive, which is not a fault in itself, and a small number of language features are deemed 'too advanced' to be covered in depth, among them generators and the 'new style' classes. These features are sketched and given use cases, and the interested reader is directed to the documentation. Other features - like the useful little enumerate(object) - are not mentioned, but you have to draw the line somewhere since the book is already large, but not unwieldy.

This book is a good example of Python culture, in the clarity of its text as much as in the quality of its code. Anyone working their way through it will have a solid foundation upon which to explore Python's potential. The following is the table of contents for this highly recommended book:

Part I. Getting Started
1. A Python Q&A Session
Why Do People Use Python?; Is Python a Scripting Language?; Okay, But What's the Downside?; Who Uses Python Today?; What Can I Do with Python?; What Are Python's Technical Strengths?; How Does Python Stack Up to Language X?;
2. How Python Runs Programs
Introducing the Python Interpreter;
Program Execution ;
Execution Model Variations;
3. How You Run Programs
Interactive Coding; System Command Lines and Files; Clicking Windows File Icons; Module Imports and Reloads; The IDLE User Interface; Other IDEs; Embedding Calls; Frozen Binary Executables; Text Editor Launch Options; Other Launch Options; Future Possibilities?; Which Option Should I Use?; Part I Exercises;

Part II. Types and Operations
4. Numbers
Python Program Structure; Why Use Built-in Types?; Numbers; Python Expression Operators; Numbers in Action;The Dynamic Typing Interlude;
5. Strings
String Literals; Strings in Action; String Formatting; String Methods; General Type Categories;
6. Lists and Dictionaries
Lists; Lists in Action; Dictionaries; Dictionaries in Action;
7. Tuples, Files, and Everything Else
Tuples; Files; Type Categories Revisited; Object Generality; References Versus Copies; Comparisons, Equality, and Truth; Python's Type Hierarchies; Other Types in Python; Built-in Type Gotchas; Part II Exercises;

Part III. Statements and Syntax
8. Assignment, Expressions, and Print
Assignment Statements; Expression Statements; Print Statements;
9. if Tests
if Statements; Python Syntax Rules; Truth Tests;
10. while and for Loops
while Loops; break, continue, pass, and the Loop else; for Loops; Loop Variations;
11. Documenting Python Code
The Python Documentation Interlude; Common Coding Gotchas; Part III Exercises;

Part IV. Functions
12. Function Basics
Why Use Functions?; Coding Functions;A First Example: Definitions and Calls; A Second Example: Intersecting Sequences ;
13. Scopes and Arguments
Scope Rules; The global Statement; Scopes and Nested Functions; Passing Arguments; Special Argument Matching Modes;
14. Advanced Function Topics
Anonymous Functions: lambda; Applying Functions to Arguments; Mapping Functions Over Sequences; Functional Programming Tools; List Comprehensions; Generators and Iterators; Function Design Concepts; Function Gotchas; Part IV Exercises;

Part V. Modules
15. Modules: The Big Picture
Why Use Modules?; Python Program Architecture; How Imports Work ;
16. Module Coding Basics
Module Creation; Module Usage; Module Namespaces; Reloading Modules;
17. Module Packages
Package Import Basics ; Package Import Example; Why Use Package Imports?; A Tale of Three Systems;
18. Advanced Module Topics
Data Hiding in Modules; Enabling Future Language Features; Mixed Usage Modes; Changing the Module Search Path ; The import as Extension; Module Design Concepts; Module Gotchas; Part V Exercises ;

Part VI. Classes and OOP
19. OOP: The Big Picture
Why Use Classes?; OOP from 30,000 Feet;
20. Class Coding Basics
Classes Generate Multiple Instance Objects; Classes Are Customized by Inheritance; Classes Can Intercept Python Operators;
21. Class Coding Details
The Class Statement; Methods; Inheritance; Operator Overloading; Namespaces: The Whole Story;
22. Designing with Classes
Python and OOP; Classes as Records; OOP and Inheritance: "is-a" Relationships; OOP and Composition: "has-a" Relationships; OOP and Delegation; Multiple Inheritance; Classes Are Objects: Generic Object Factories; Methods Are Objects: Bound or Unbound; Documentation Strings Revisited; Classes Versus Modules;
23. Advanced Class Topics
Extending Built-in Types; Pseudo-Private Class Attributes; "New Style" Classes in Python 2.2; Class Gotchas; Part VI Exercises;

Part VII. Exceptions and Tools
24. Exception Basics
Why Use Exceptions?; Exception Handling: The Short Story; The try/except/else Statement; The try/finally Statement; The raise Statement; The assert Statement ;
25. Exception Objects
String-Based Exceptions; Class-Based Exceptions; General raise Statement Forms;
26. Designing with Exceptions
Nesting Exception Handlers; Exception Idioms; Exception Design Tips; Exception Gotchas; Core Language Summary; Part VII Exercises;

Part VIII. The Outer Layers
27. Common Tasks in Python
Conversions, Numbers, and Comparisons; Manipulating Strings; Data Structure Manipulations; Manipulating Files and Directories; Internet-Related Modules; Executing Programs ; Debugging, Testing, Timing, Profiling; Exercises;
28. Frameworks
An Automated Complaint System ; Interfacing with COM: Cheap Public Relations; A Tk-inter-Based GUI Editor for Managing Form Data; Jython: The Felicitous Union of Python and Java; Exercises;
29. Python Resources
Layers of Community; The Process; Services and Products; The Legal Framework: The Python Software Foundation; Software; Popular Third-Party Software; Web Application Frameworks; Tools for Python Developers;

Part IX. Appendixes
A. Installation and Configuration
B. Solutions to Exercises

5 stars Learning Python

2005-10-17     2 of 5 found this review helpful

You can always depend on the O'Reilly "Learning" series to provide an excellent detailed introduction to any language. You will be up and running after you read this book.

My only complaint is the same material was covered several times as it was expanded in detail.

4 stars Title is very accurate: "Learning"

2005-10-03     2 of 3 found this review helpful

If you want to LEARN Python, this book is a good place to start. The syntax is thoroughly covered, but if you have not had experience with a pointer-based language (C or C++), you may have a difficult time grasping the concept of references.

The book does not cover more advanced topics like sockets and threads. I believe the "Programming Python" book covers those topics. I also have not seen any mention of databases or extensions like PyGreSQL.

Basically, if you want to learn the language, this is your book. If you want to code professionally in Python, you will need at least another book in conjunction with this one or instead of this one.

3 stars Learning Python - Teachers and Beginners Beware

2004-07-03     2 of 7 found this review helpful

I can readily subscribe to almost all of the nice things already said about Python. I've been programming Perl for 10 plus years and also C, C++, Java and lots more. In short, I'm a very experienced programmer. I've also had a lot of teaching experience at the college Computer Science level and within companies that I've worked at. My idea of a great Learning XXX book is the Learning Perl book by R. Schwartz and T. Phoenix (O'Reilly). Learning Python is definitely not in the same league as a teaching and self-instruction book. I need a Python book for an upcoming course that I will be teaching. The course will cover both Perl and Python. I have used and will use Learning Perl. My Python book needs to be, oh say about the same size as Learning Perl and will take the user to about the same level of proficiency. This book is not it. The book is way too heavy in bulk and presentation. Just compare for yourself, the Table of Contents for the two books, available on the Amazon.com page. Way too much for a Learning Python course. Teachers and Students - "Caveat Emptor" (=Let the buyer beware)

4 stars Good if you already know programming little bit.....

2001-12-27     2 of 5 found this review helpful

This book is pretty good for those who already know programming [such in c++/c/etc..] a little bit. If you have no experience in programming you might get lost sometime. After all this book gives the flavor of Python doesn't go very deep for example it doesn't say how to search in a list or it doesn't talk about advanced mathematical calculation on Matrix even though Python has impressive built-in functions for Matrix calculation. So far I liked this book and if I wanted to know more I had to search on the internet. After all I liked this book. I am thinking to buy another book which covers more advanced topics and STL stuffs. Hope you will be able to ... thanks and good luck.

1 stars learning python

2000-05-27     2 of 15 found this review helpful

unlike other people who had such a wonderful experience with the book, mine was a complete disaster.The first chapter was dedicated to running the program, and modules files, in the second chapter author would give a code example and end it with comments like" we will explain the concept in later chapters" that turned me off cause if you going to use an example expalin it or give an example that's pertains with the chapter. furthermore, later chapters of the book, were written with sample code with no Explanation at all. what good is it going to do me? a code without Explanation.. Anyway i am looking for a more detailed book on python. If anyone can help me out please post a note. thanks

5 stars is to Python what the Llama book is to Perl

1999-06-09     2 of 3 found this review helpful

An excellent tutorial to get started in doing Python work. The sections are nicely ordered along with plenty of handy reference tables and explanations. Not only will this book tell you *what* to do, but *why* you're doing it - unlike so many other so-called tutorials. After getting this book, I was getting Real Work done in Python in a matter of hours.

2 stars Decent book, bad editing (kind of)

2008-10-18     1 of 1 found this review helpful

I wanted to like this book. As a general rule, I give the benefit of a doubt to O'Reilly books, and rarely am I mistaken. But this was one of the rare exceptions. In my experience, there are two trains of thought when it comes to learning a programming language:
1) Start right in with a book, using it to familiarize yourself with the language while you use the language to start fleshing out stuff that you learn in the book -- let's call this the "synergistic" or maybe "complementary" approach: using the book complements the coding you try, which, in turn, lets you put stuff you're learning into a workable framework.
2) Read the whole book through, and then apply what you've learned.

Personally, I don't know anyone with a good enough memory to really be able to pull off #2. But, honestly, it's more about patience than memory: people get excited about a language, and want to start using it. Having to (pretty much) read a whole book before you can start digging in is a bit of an anti-climax. The problem is that that's what you have to do with _Learning Python_. For example, one of the fundamentals of almost all programming languages is how looping is accomplished. In _Learning Python_, looping isn't discussed in detail until you're almost *250* pages into the book. Instead, the very, very fundamentals of the language are gone over in excruciating detail. Honestly, if you'd never programmed before, this might actually be a helpful, good thing. If, on the other hand, you've had pretty much any other programming experience, the pace is slow and tedious. I found myself yearning to be *doing* something, and instead was just plodding along.

If you have had previous programming experience, and are relatively well-versed with how languages work, I have to recommend _Python Essential Reference_ by David M. Beazley. Just read its first chapter in the bookstore, and you'll find yourself becoming quickly enlightened.

5 stars Great introductory book

2008-08-07     1 of 2 found this review helpful

This is a really good introduction to Python. It is very clear, accessible and has quite a lot of substantial content. It does not get into the really deep details, but that is OK because if it tried to the book would become overwhelming. On the other hand, unlike some python books it is not so light and superficial to be good for newbies only. I think this is a great starter book on Python.

4 stars Learning Python, 3rd Edition

2007-12-07     1 of 1 found this review helpful

This book is a very good starting point for new Python users. It is direct and easy to follow. I was happy to see that the 3rd edition was in print dealing with the latest 2.5 version of Python.

5 stars My brothers is loving it and says its really easy

2007-03-12     1 of 8 found this review helpful

I bought this for my brother so I what I can tell you is what he tells me. He says that Python is really easy to learn, its very useful and the book is really ease to follow. He works with GIS software and that is what Python is for. He is enjoying the book very much and is very grateful with my choice! So I am happy I chose this book too!

4 stars Great Overview, Even if It is Slightly Dated...

2007-03-08     1 of 1 found this review helpful

Even though this book is a little dated, it still provides an excellent overview of the language and provides a great "pick and choose" reading format. There's a lot of useful, straightforward/clear information.

The organization of the book makes it a wonderful reference as well as an easy read. The ability to skim over certain sections when you already understand some base concepts makes it a wonderful, inexpensive intro/reference to/for Python for experienced developers.

4 stars good reference and beginner's manual

2007-01-17     1 of 2 found this review helpful

It's a good book. Absolutely worth the money if you're leaning Python. It has tutorials and explains things nicely. Sometimes it can be a little too verbose about computer science basics (explaining variables, etc.) which can be good for beginners but is annoying if you already know. Does a good job at covering what you need to know about Python, and not bad for the price.

4 stars good beginner's book

2006-12-06     1 of 1 found this review helpful

I was entirely new to programming when this caught my eye; but I read it and got really into it. It's a great beginner's guide to python, but also to object-oriented languages in general. It goes from very basic, like the simple "print" statement to Java and C integration. From what I hear, it's also a great start to python to already-seasoned programmers. I found some parts about OOP dificult to understand, so I reccommend Python Programming for the Absolute Beginner (premier press).

5 stars Excellent book....great for electrical engineers dabbling with scripts!!

2006-11-10     1 of 1 found this review helpful

I have been a user of Perl for about 3 years...i would rate myself as an intermediate level programmer and I use a lot of Perl and shell scripting for clean-up, text processing in my research.
After a point I realized that I was hardly re-using my code in Perl...i used to just write up a script everytime it beckoned. I also started finding it extremely hard to maintain and even understand code that i had written a few years back. Electrical Engineers are super efficient at getting something done but not always with programming elan and elegance!!

I decided to move to Python...and this book is an excellent start...though it sounds like it is for beginners...it is nice to review the initial stuff to contrast with perl and it is reasonably exhaustive. I have found it much easier to maintain code and other people in my lab have also started using my code as it is much easier to understand. The object-oriented approach is an extra-incentive to think more in terms of C++....code is in general clean and quite-efficient (not as much as C..since it is byte-code).

All electrical engineers who use a lot of shell scripting and aren't experts in programming, moving to python will definitely offer more flexibility and is much faster to implement than C or C++. And this is a pretty decent book (check out Van Rossum's tutorial or something on the web to get