The Practice of Programming

The Practice of Programming
by Brian W. Kernighan, Rob Pike

The Practice of Programming
List Price: $49.99
Our Price: $29.80
You Save: $20.19 (40%)
Availability: Usually ships in 1-2 business days
Buy Used: from $5.99 (click here)
Category: Book
See more book details and other editions


(Click here)
Buy this book at online book store in your country
Canada | UK | Germany | France

Book Summary Information

Author: Brian W. Kernighan, Rob Pike
Edition: Paperback
Audio: English (Unknown); English (Original Language); English (Published)
Published: 1999-02-14
ISBN: 020161586X
Number of pages: 288
Publisher: Addison-Wesley Professional

Book Reviews of The Practice of Programming

Book Review: Simple and excellent
Summary: 5 Stars

I am bemused by the disparaging comments of my fellow readers in regard to this book. Kernighan and Pike make clear their intent in the first paragraph of the preface to this book; it is about simplicity, clarity, and generality.

To be sure, there is tinder here for short tempers and delicate egos. If you're under the gun, trying to duct-tape together the fifth release of some huge, unwieldy application, this book does not contain the short-term quick fixes you've been hoping for. If you're righteously convinced of your own sound practices and don't care to look at someone else's methods, this book may irk you.

Kernighan and Pike have written a book about the most basic habits and outlook that a programmer should have. They have not tried to address all facets of programming. Instead, they sacrifice scope to make their points stand out all the more clearly.

Would this be a better book if they had cast their net wider? Hardly. If you start off by applying the carefully thought out, methodical approaches described clearly throughout this book, your code will still hit abstruse bumps and strange circumstances. But most problems will succumb to the same analytical ways of thinking and tools that Kernighan and Pike have laboured to describe with such clarity.

But don't imagine that I think this book is perfect; the authors have been doing many things in the same ways for a long time. Most often, this is because their methods are effective, but sometimes they are far too close to being cop-outs. For example, the idea that it's OK to just print an error message and bomb out if something goes wrong is laughable outside of the Unix command line environment, and is rarely appropriate even there.

Fundamentally, though, if you can't solve the problems at the ends of the chapters (they're easy), or you think you can't possibly benefit from reading a book that troubles to describe quicksort (which you probably learned in CS-201), then there is likely nothing for you here. At least until you think to question your perspectives. Until then, I'll confess to a sense of relief that I don't have to work with you :-)

Summary of The Practice of Programming

With the same insight and authority that made their book The Unix Programming Environment a classic, Brian Kernighan and Rob Pike have written The Practice of Programming to help make individual programmers more effective and productive. This book is full of practical advice and real-world examples in C, C++, Java, and a variety of special-purpose languages. Kernighan and Pike have distilled years of experience writing programs, teaching, and working with other programmers to create this book. Anyone who writes software will profit from its principles and guidance.
Coauthored by Brian Kernighan, one of the pioneers of the C programming language, The Practice of Programming is a manual of good programming style that will help any C/C++ or Java developer create faster, more maintainable code.

Early sections look at some of the pitfalls of C/C++, with numerous real-world excerpts of confusing or incorrect code. The authors offer many tips and solutions, including a guide for variable names and commenting styles. Next, they cover algorithms, such as binary and quick sorting. Here, the authors show how to take advantage of the built-in functions in standard C/C++. When it comes to data structures, such as arrays, linked lists, and trees, the authors compare the options available to C, C++, Java, and even Perl developers with a random-text-generation program (using a sophisticated Markov chain algorithm) written for each language.

Subsequent sections cover debugging tips (including how to isolate errors with debugging statements) and testing strategies (both white-box and black-box testing) for verifying the correctness of code. Final sections offer tips on creating more portable C/C++ code, with the last chapter suggesting that programmers can take advantage of interpreters (and regular expressions) to gain better control over their code. A handy appendix summarizes the dozens of tips offered throughout the book.

With its commonsense expertise and range of examples drawn from C, C++, and Java, The Practice of Programming is an excellent resource for improving the style and performance of your code base. --Richard Dragan

Languages & Tools Books

Book Subjects
Most talked about in Languages & Tools Books
Eclipse Plug-ins (3rd Edition) ImageEclipse Plug-ins (3rd Edition)
by Eric Clayberg, Dan Rubel
Addison-Wesley Professional; Published: 2008-12-21; Paperback; Book
Best price: $38.33
Price in other shops: $59.99
Java Software Solutions: Foundations of Program Design (6th Edition) ImageJava Software Solutions: Foundations of Program Design (6th Edition)
by John Lewis, William Loftus
Addison Wesley; Published: 2008-03-07; Paperback; Book
Best price: $74.40
Price in other shops: $128.00
C++ Primer (3rd Edition) ImageC++ Primer (3rd Edition)
by Stanley B. Lippman, Josée Lajoie
Addison-Wesley Professional; Published: 1998-04-02; Paperback; Book
Best price: $14.47
Price in other shops: $49.99
Accelerated C++: Practical Programming by Example ImageAccelerated C++: Practical Programming by Example
by Andrew Koenig, Barbara E. Moo
Addison-Wesley Professional; Published: 2000-08-24; Paperback; Book
Best price: $26.99
Price in other shops: $49.99
Patterns of Software: Tales from the Software Community ImagePatterns of Software: Tales from the Software Community
by Richard P. Gabriel
Oxford University Press, USA; Published: 1998-05-28; Paperback; Book
Best price: $64.55
Just Java? 2 (6th Edition) ImageJust Java? 2 (6th Edition)
by Peter van der Linden
Prentice Hall; Published: 2004-07-01; Paperback; Book
Best price: $35.00
Price in other shops: $64.99
UML for Java? Programmers ImageUML for Java? Programmers
by Robert C. Martin
Prentice Hall; Published: 2003-06-06; Paperback; Book
Best price: $15.00
Price in other shops: $44.99
Thinking in Java (3rd Edition) (One-Off) ImageThinking in Java (3rd Edition) (One-Off)
by Bruce Eckel
Prentice Hall PTR; Published: 2002-12-06; Paperback; Book
Best price: $13.80
Price in other shops: $54.99
SQL Fundamentals with CDROM ImageSQL Fundamentals with CDROM
by John J. Patrick
Prentice Hall; Published: 1999-05-11; Paperback; Book
Best price: $12.00
Price in other shops: $44.99
C How to Program, 2nd Edition ImageC How to Program, 2nd Edition
by Paul J. Deitel
Prentice Hall; Published: 1994-01-13; Textbook Binding; Book
Best price: $25.84
Price in other shops: $70.00
Similar Books and other products
Structure and Interpretation of Computer Programs - 2nd Edition (MIT Electrical Engineering and Computer Science) ImageStructure and Interpretation of Computer Programs - 2nd Edition (MIT Electrical Engineering and Computer Science)
by Harold Abelson, Gerald Jay Sussman
The MIT Press; Published: 1996-09-01; Paperback; Book
Best price: $33.74
Price in other shops: $46.00
The Mythical Man-Month: Essays on Software Engineering, Anniversary Edition (2nd Edition) ImageThe Mythical Man-Month: Essays on Software Engineering, Anniversary Edition (2nd Edition)
by Frederick P. Brooks
Addison-Wesley Professional; Published: 1995-08-12; Paperback; Book
Best price: $21.47
Price in other shops: $39.99
Design Patterns: Elements of Reusable Object-Oriented Software ImageDesign Patterns: Elements of Reusable Object-Oriented Software
by Erich Gamma, Richard Helm, Ralph Johnson, John Vlissides
Addison-Wesley Professional; Published: 1994-11-10; Hardcover; Book
Best price: $35.45
Price in other shops: $59.99
Algorithms in C++, Parts 1-4: Fundamentals, Data Structure, Sorting, Searching, Third Edition ImageAlgorithms in C++, Parts 1-4: Fundamentals, Data Structure, Sorting, Searching, Third Edition
by Robert Sedgewick
Addison-Wesley Professional; Published: 1998-07-23; Paperback; Book
Best price: $44.97
Price in other shops: $69.99
Fundamentals of Data Structures in C ImageFundamentals of Data Structures in C
by Ellis Horowitz, Sartaj Sahni, Susan Anderson-Freed
Silicon Pr; Published: 2007-08; Paperback; Book
Best price: $49.99
Price in other shops: $89.95
Programming Pearls (2nd Edition) ImageProgramming Pearls (2nd Edition)
by Jon Bentley
Addison-Wesley Professional; Published: 1999-10-07; Paperback; Book
Best price: $24.91
Price in other shops: $39.99
Code Complete: A Practical Handbook of Software Construction ImageCode Complete: A Practical Handbook of Software Construction
by Steve McConnell
Microsoft; Microsoft Press; Published: 2004-07-07; Paperback; Book
Best price: $27.54
Price in other shops: $49.99
Unix Programming Environment (Prentice-Hall Software Series) ImageUnix Programming Environment (Prentice-Hall Software Series)
by Brian W. Kernighan, Rob Pike
Prentice Hall Ptr; Published: 1984-03; Paperback; Book
Best price: $36.98
Price in other shops: $66.00
The Pragmatic Programmer: From Journeyman to Master ImageThe Pragmatic Programmer: From Journeyman to Master
by Andrew Hunt, David Thomas
Addison-Wesley Professional; Published: 1999-10-30; Paperback; Book
Best price: $35.60
Price in other shops: $49.99
C Programming Language (2nd Edition) ImageC Programming Language (2nd Edition)
by Brian W. Kernighan, Dennis M. Ritchie
Prentice Hall; Published: 1988-04-01; Paperback; Book
Best price: $34.99
Price in other shops: $67.00
Book store. Illustrated catalog of books on different categories