views:

1014

answers:

9

There have been several questions here on SO about resources for learning Python (which have been most helpful,) but I was wondering if there was some consensus in the Python community about what the definitive reference book was once you knew the language?

I'm hoping for something along the same lines as K&R's "The C Programming Language," or Larry Wall's "Programming Perl." Any suggestions would be most appreciated.

(Edit: again, I'm not looking for a tutorial or an introduction, I was hoping for a solid reference that I could get at when I didn't have access to the web.)

+7  A: 

Mark Lutz's Programming Python.

Though I am also fond of Python Essential Reference.

Joe Skora
+12  A: 

I have to say I like the documentation that comes with the language. This seems to be the definitive reference that's constantly smacked into new people in the #python chatroom on freenode.

Edit: You can download the python documentation to your computer. If you are using Windows the CHM version is excellent.

epochwolf
I agree. I have one Python book (Python Phrasebook) vs. a stack of Java books that outweighs me.
Bill the Lizard
I have Programming Python but it's more of a teaching book than a reference. :) Otherwise the docs have been good enough for most things.
epochwolf
I think the docs are great, don't get me wrong (and the CHMs are fully ensconced on my hard drive) I was just wondering what else there was.
Electrons_Ahoy
+2  A: 

Programming Python and probably Python Essential Reference - and of course docs.python.org can be considered the most complete/useful/up-to-date reference (for offline use see the Download section).

VolkA
+4  A: 

Core Python Programming
It gives a thorough discussion of the core language, including some very lucid discussion of the wonkier aspects of the language (such as generators, list comprehensions). I found the coverage of the built in data structures very handy. This book is a good reference.

Programming Python A good tutorial that walks through a lot of the libraries and gives plenty of motivating examples. I think this is a great book to start on the language.

Python Essential Reference
Good reference on the standard library. Getting a little dated though.

UPDATE: Python Essential Reference, 4th edition is now out. It updates for both 2.6 and 3.0. Very well done.

John Mulder
+1  A: 

another vote for: Core Python Programming:
http://www.amazon.com/Core-Python-Programming-2nd/dp/0132269937

Corey Goldberg
+13  A: 

You shouldn't neglect Mark Pilgrim's excellent "Dive into Python":

http://diveintopython.org/

caseman
+5  A: 
  • My favorite is Python in a nutshell. I always have a copy on my desk, as well as on my Safari account.
  • I also keep the official documentation on my laptop.
  • A pydoc HTTP server (pydoc -p portnumber) is always running in the background.
codeape
A: 

Dive into Python is good, but the original is getting dated.

Luckily, there is an updated version, atleast online, I'm not certain if it's also available on dead trees yet: http://diveintopython3.org/

Agrajag