Industrial-Sized Deals TextBTS15 Shop Women's Handbags Learn more nav_sap_plcc_6M_fly_beacon $5 Albums $5 Off Fire TV Stick Off to College Essentials Shop Popular Services TransparentGGWin TransparentGGWin TransparentGGWin  Amazon Echo Starting at $99 Kindle Voyage Gear Up for Football Baby Sale

C Traps and Pitfalls
Format: PaperbackChange
Price:$30.15+Free shipping with Amazon Prime
Your rating(Clear)Rate this item


There was a problem filtering reviews right now. Please try again later.

20 of 21 people found the following review helpful
If you program in C or C++, you must read this book if you want to consider yourself a superior programmer. If you are a college student, definitely read this book. Koenig fills in a lot of gaps left by authors of introductory books on C or C++. Why do I mention C++? Because C++ is far more than just objects and classes. The lower level implementation of functions is still basically C programming. He includes chapters on linkage, the preprocessor, and portability. It is a short book that is definitely worth reading.
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
19 of 20 people found the following review helpful
on May 13, 1997
This is among the five "must have" books on the astute C programmer's bookshelf. Actually, it spends little time on the shelf since one refers to it time and time again. This slim volume packs a lot of information about those "gotchas" that still "getcha" (when you least expect it). The Introduction is "Chapter 0", your first hint that Koenig knows and respects the subject. His treatment of unscrambling complex declarations is especially good.

Why a 9 instead of a 10? Simple. Andy: please release a new version! The ANSI/ISO standard is almost ten years old. :)
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
14 of 16 people found the following review helpful
on November 21, 2008
I'd recommend this book for novice C programmers, people with two or less years of coding experience. However, this 1989 book focuses on pre-ANSI C, so the novice would need to be guided by someone that knows the history of C. Some of his statements are false when applied to ANSI C with prototypes (e.g., p.139, it _is_ possible to pass a char argument, if there is a function prototype). I read through and did the problems in this slim book in about three hours. It does have a few nuggets of value, and introduced me to a bug I'd not seen before, the reverse of the "= for ==" bug:
while( (x == fgetc(f)) != EOF )
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
4 of 4 people found the following review helpful
If you have to write in C, then yes, it is still worth reading a good, short book about C even if it was written in 1989. It can get a bit boring to read the details of selected problems and solutions in C cover-to-cover, but it's only 100 pages. An experienced C programmer will probably know many of these answers, and can skim over what's not new. But if you hit even one pitfall which is new to you, or which you have not made the effort to avoid, then the book was worth it. The bonus is the last chapter, "Advice". It's only a few pages, and is followed by answers to exercises. But I think it has more meaning if you do leave it until the end of your reading.

(One caveat: Since Koenig was writing before long variable names were common, his examples do not serve as best practice for modern variable-naming in an IDE with auto-complete.)
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
13 of 17 people found the following review helpful
on July 23, 1999
Along with Holub's 'The C Companion', this is one of the few programming books that I've read in 13 years of C programming that talks about real programming issues instead of simply rehashing what a for loop is. A must read for C programmers.
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
2 of 2 people found the following review helpful
on December 22, 2007
To preface my review, I learned how to program in C four years ago as an undergraduate engineer, but didn't really get into it until I started my graduate studies about a year and a half ago. I would describe myself as a very competent C programmer, but by no means an expert.

There are many doorstops that call themselves C programming reference books, including the one that I used as an undergrad. This book should be on any C programmer's shelf as the first go-to guide during debuggings. I found this book very helpful, despite the fact that it is almost 20 years old (pre-ANSI C). It highlights many issues that I have pulled my hair out trying to find and fix in the programs I have written over the years, and also some new bugs that have yet to bite me. Perhaps my original C text wasn't the best to begin with, but the proper usage of many aspects of C have been explained to me with this text, such as safely writing macros and using the static keyword (especially with multiple-file programs), just to name a few. He also explains (in an appendix) using the library variable-argument functions, which I have been trying to get working without any success...until now.

This is a small book, and I read a chapter or two every night for a few days. Programming isn't exactly page-turning literature, but the author makes his point clearly and concisely. I highly recommend this book for students and practicing programmers alike.
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
1 of 1 people found the following review helpful
on March 13, 2015
This is at the the top of my "Canon" of books for those who want to learn how to program at the highest levels of excellence.
There are some things which are hard to keep your mind thinking right while programming, and this zeroes in on them.
Like the "Monty Hall" paradox", you have to pause to get the number of fence posts required for a fence of length N right. Your mind's immediate thought will usually be close - but wrong. This book takes those problems (and many are beyond just the C language itself) so when you start coding into one of these areas you pause and double-check your logic and verify it will do what you think it does.
(The next two books in my canon are "Programming Pearls" and "More Programming Pearls" - others concern management, and there are many current and popular books, but many will miss the Classics that have wisdom which has stood the test of time).
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
on May 25, 2014
While working at AT&T in the 1980s, the author kept note of C features that frequently were a source of confusion, and eventually compiled his notes into a long article. This book is an expansion of that article with the addition of long sections on the more general topics of prototypes, macros, pointers vs. arryas, and platform dependencies. The writing is clear and brief, although the topics of the longer sections would be better covered in a good C tutorial book. The original article is available online and I think it contains all the most interesting bits from the book. While some of the material is dated, and the gotchas listed should be well covered in any of the more thorough C introductions, the article/book is good for a quick survey.
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
on February 21, 2014
This is a very small book but clarifies a lot of internals of programming language. This is a must read for any programmer. It will help you improve your understanding of C and C part of C++.
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
on June 8, 2014
Some of the lessons are a lot less applicable now, but the entirety of the book is an interesting glance into history and explains many of the reasons C is the way it is!
0CommentWas this review helpful to you?YesNoSending feedback...
Thank you for your feedback.
Sorry, we failed to record your vote. Please try again
Report abuse
     
 
Customers who viewed this also viewed
The C Puzzle Book
The C Puzzle Book by Alan R. Feuer (Paperback - October 25, 1998)
$16.74

Expert C Programming: Deep C Secrets
Expert C Programming: Deep C Secrets by Peter van der Linden (Paperback - June 24, 1994)
$29.43

The C Programming Language
The C Programming Language by Brian W. Kernighan (Paperback - April 1, 1988)
$51.80
 
     

Send us feedback

How can we make Amazon Customer Reviews better for you?
Let us know here.