|
Learning Python: Powerful Object-Oriented Programming (Animal Guide) |  | Author: Mark Lutz Publisher: O'Reilly Media Category: Book
List Price: $54.99 Buy New: $29.64 as of 3/10/2010 08:14 UTC details You Save: $25.35 (46%)
New (23) Used (7) from $29.64
Seller: stage_coach_books Rating: 147 reviews Sales Rank: 3899
Media: Paperback Edition: 4th Pages: 1216 Number Of Items: 1 Shipping Weight (lbs): 3.6 Dimensions (in): 9.1 x 7 x 2.7
ISBN: 0596158068 Dewey Decimal Number: 005.133 EAN: 9780596158064 ASIN: 0596158068
Publication Date: September 24, 2009 Availability: Usually ships in 1-2 business days
| |
| Also Available In:
|
| Similar Items:
| |
| Editorial Reviews:
Amazon.com Review The authors of Learning Python show you enough essentials of the Python scripting language to enable you to begin solving problems right away, then reveal more powerful aspects of the language one at a time. This approach is sure to appeal to programmers and system administrators who have urgent problems and a preference for learning by semi-guided experimentation. First off, Learning Python shows the relationships among Python scripts and their interpreter (in a mostly platform-neutral way). Then, the authors address the mechanics of the language itself, providing illustrations of how Python conceives of numbers, strings, and other objects as well as the operators you use to work with them. Dictionaries, lists, tuples, and other data structures specific to Python receive plenty of attention including complete examples. Authors Mark Lutz and David Ascher build on that fundamental information in their discussions of functions and modules, which evolve into coverage of namespaces, classes, and the object-oriented aspects of Python programming. There's also information on creating graphical user interfaces (GUIs) for Python applications with Tkinter. In addition to its careful expository prose, Learning Python includes exercises that both test your Python skills and help reveal more elusive truths about the language.
Product Description
Google and YouTube use Python because it's highly adaptable, easy to maintain, and allows for rapid development. If you want to write high-quality, efficient code that's easily integrated with other languages and tools, this hands-on book will help you be productive with Python quickly -- whether you're new to programming or just new to Python. It's an easy-to-follow self-paced tutorial, based on author and Python expert Mark Lutz's popular training course. Each chapter contains a stand-alone lesson on a key component of the language, and includes a unique Test Your Knowledge section with practical exercises and quizzes, so you can practice new skills and test your understanding as you go. You'll find lots of annotated examples and illustrations to help you get started with Python 3.0. - Learn about Python's major built-in object types, such as numbers, lists, and dictionaries
- Create and process objects using Python statements, and learn Python's general syntax model
- Structure and reuse code using functions, Python's basic procedural tool
- Learn about Python modules: packages of statements, functions, and other tools, organized into larger components
- Discover Python's object-oriented programming tool for structuring code
- Learn about the exception-handling model, and development tools for writing larger programs
- Explore advanced Python tools including decorators, descriptors, metaclasses, and Unicode processing
|
| Customer Reviews:
Showing reviews 1-5 of 147
Good book February 22, 2010 Fei Meng (Raleigh, NC, USA) both python 2.6 and 3.0 are covered in this book. low price compared to other python books. Have a try.
Comprehensive and easy to read January 31, 2010 Franz Wahl 1 out of 1 found this review helpful
The book is a good introduction for new programmers. In addition it has references to other languages like C++ which makes the book exiting for more expierenced fellows. The book can be recommended equally for studying Python and as a reference book.
Great for learning the CORE language ... January 18, 2010 M. Lee 3 out of 3 found this review helpful
import my_four_recommendations:
from bookshelf import "Learning Python 4th ed. - by Lutz/O'Reilly", "Beginning Python from Novice to Professional - by Lie Hetland/Apress", "The Quick Python Book - by Ceder/Manning", "Python Programming on Win32 - by Mark Hammond"
############################
#Comparative overview
############################
I have the four books above. They all have their strengths and weaknesses, but are all of very high quality overall.
However the Lutz/O'Reilly book has more pages, and is more comprehensive, and is probably my favorite for learning the CORE LANGUAGE from straight beginner level. It can be verbose, and goes through every detail of the language, from the very basic stuff to the very high level stuff listing every sort of avenue/path you could potentially take in utilising the language, and explains it in very clear, plain and concise prose. Good examples after each instance of a new concept, and also examples of errors for illustration purposes if you were to not write the code in the right way is very helpful.
A detailed example would be the following on OPENING FILES. Here are three passages from each book explaining the same concept:
Lutz p.230-233 on "Opening Files":
###The Lutz book lists all filetype operations in a table first###
"To open a file, a program calls the built-in open function, with the external filename
first, followed by a processing mode. The mode is typically the string 'r' to open for
text input (the default), 'w' to create and open for text output, or 'a' to open for
appending text to the end. The processing mode argument can specify additional
options:
*Adding a b to the mode string allows for binary data (end-of-line translations and
3.0 Unicode encodings are turned off).
*Adding a + opens the file for both input and output (i.e., you can both read and
write to the same file object, often in conjunction with seek operations to reposition
in the file).
Both arguments to open must be Python strings, and an optional third argument can
be used to control output buffering--passing a zero means that output is unbuffered
(it is transferred to the external file immediately on a write method call). The external
filename argument may include a platform-specific and absolute or relative directory
path prefix; without a directory path, the file is assumed to exist in the current working
directory (i.e., where the script runs). We'll cover file fundamentals and explore some
basic examples here, but we won't go into all file-processing mode options; as usual,
consult the Python library manual for additional details."
#The Lutz book then shows three specific examples of opening files 'In Action'. These examples go on for about 1-2 pages after the initial opening paragraph as aforementioned above.
-------------------
Lie Hetland/Apress p. 255 on "Opening Files":
"You can open files with the open function, which has the following syntax: open(name[, mode[, buffering]])
The open function takes a file name as its only mandatory argument, and returns a file object. The mode and buffering arguments are both optional and will be explained in the material that follows.
So, assuming that you have a text file (created with your text editor, perhaps) called
somefile.txt stored in the directory C:\text (or something like ~/text in UNIX), you can
open it like this:
>>> f = open(r'C:\text\somefile.txt')
If the file doesn't exist, you may see an exception traceback like this:
Traceback (most recent call last):
File "", line 1, in ?
IOError: [Errno 2] No such file or directory: "C:\\text\\somefile.txt"
You'll see what you can do with such file objects in a little while, but first, let's take a look
at the other two arguments of the open function."
--------------------
Ceder/Manning p. 159-160 on "Opening Files":
"In Python, you open and read a file using the built-in open function and various
built-in reading operations. The following short Python program reads in one line
from a text file named myfile:
file_object = open('myfile', 'r')
line = file_object.readline()
open doesn't read anything from the file; instead it returns an object called a file
object that you can use to access the opened file. A file object keeps track of a file
and how much of the file has been read or written. All Python file I/O is done using
file objects rather than filenames.
The first call to readline returns the first line in the file object, everything up to
and including the first newline character or the entire file if there is no newline char-
acter in the file; the next call to readline would return the second line, and so on.
The first argument to the open function is a pathname. In the previous example,
we're opening what we expect to be an existing file in the current working directory.
The following opens a file at the given absolute location:
import os
file_name = os.path.join("c:", "My Documents", "test", "myfile")
file_object = open(file_name, 'r')"
###############
As you can see the Lutz/O'Reilly is alot more comprehensive when it talks about the core language, explaining in detail how the language works behind the scenes. The Lie Hetland book tries to be very brief and concise but more broad.
The Manning book is probably best for people who already know Python and are looking for a quick reference to rejog the memory, since it is condensed to the most important features, functions and concepts in Python.
I think the titles do a good job of representing each book;
"Learning Python" is meant to be for beginners learning the language thoroughly.
"Beginning Python From Novice to Professional" is good for those who want to go quickly from the Novice to Professional spectrum. Perhaps good for people with a good background in other languages.
And "The Quick Python Book" is probably for those who are well versed in other languages as well as know Python already.
################################################
#Advanced features not included in the Lutz book
################################################
The biggest drawback to the Lutz/O'Reilly book is that it doesn't include advanced modules like the 'urllib', 'csv', win32/COM and the 'xml' modules. These modules were specifically of interest to me, and I had to source that from the Lie Hetland/Apress book. (For more info on win32COM + Python, see Mark Hammond's book; "Python Programming on Win32).
The Lutz book seems more comprehensive on explaining the LANGUAGE and how to master it, whilst the Lie Hetland/Apress book does this also, but goes into the more advanced features of Python and its usefulness and power for the real world. For example there is more discussion on how best to make use of Python for your needs at an advanced level, like how to go about extending/implementing Jython, IronPython or the different GUI packages out there for use. Lutz' book has none of this in any detail.
"""
#Note:
If you're buying computer programming books, it makes more sense to buy it in digital form. As you can use the search function, as opposed to hardcopy where it's probably harder to search for specific terms and symbols that relate directly to your query/problem.
Another book you could look at that I have not used is Wesley Chun's "Core Python Programming" or Mark Summerfield's "Programming in Python 3". Summerfield's book is more recent in terms of the currency of the language, however Lutz' book reviewed here is more up to date in terms of publication.
"""
Great Intro to Python January 8, 2010 Lewis (Columbia, SC) 1 out of 1 found this review helpful
I probably wouldn't recommend this book as your 'First intro to programming...' or anything, but for anyone with moderate exposure to programming or scripting that really wants an indepth introduction to Python, this book is great. (and it would work for a dedicated beginner; it isn't terribly advanced, it just doesn't show enough programs IMHO to suit a beginner that wants to start 'doing stuff').
If you aren't sure you want to learn Python, go work through a web tutorial first and make sure you like it enough to commit to such a large tome (the one at [...] is a fine intro). That's what I did. When I wanted more, I turned to this book and could not be happier.
For serving its purpose though, I give it Five Stars.
It could have used some more examples, but that is what 'Programming Python' is for...
It could have used some reference lists, but that is what 'Python Pocket Reference' is for...
(I wouldn't want to have to carry this thing around with me for reference anyway!)
As far as a very thorough discussion of the basic language features of Python 3 (and 2.6, with differences pointed out), I felt that I got more than my money's worth out of this book (and went out and bought the other two companion books after reading this one and enjoying it so much).
I feel that I got a more thorough introduction to Python from this book than I received from a semester long C++ class with a slightly larger textbook, and I was able to go back and easily rework all my C++ assignments in Python after I finished (granted, Python made some but not all of them trivial). And it also left we well prepared to knock out a number of problems on [...] once I finished (granted a lot of them test your math more than your programming, but still).
After finishing those tasks, I am looking forward to reading through 'Programming Python' and getting a better introduction to the library.
Very good November 29, 2009 Evaldo Jr Bento (Brazil) 0 out of 3 found this review helpful
This is an excelent book if you want to learn about the Python language. I recomend!
Showing reviews 1-5 of 147
|
|
| All prices are in US dollars and are provided by Amazon web services. There maybe shipping restrictions on some items. CERTAIN CONTENT THAT APPEARS ON THIS SITE COMES FROM AMAZON SERVICES LLC. THIS CONTENT IS PROVIDED ‘AS IS’ AND IS SUBJECT TO CHANGE OR REMOVAL AT ANY TIME. Powered by Apache on Ubuntu Linux with php5, xml, mod_rewrite | |