MessiandNeymar

  • Subscribe to our RSS feed.
  • Twitter
  • StumbleUpon
  • Reddit
  • Facebook
  • Digg

Friday, January 25, 2013

Debugging: a very short review

Posted on 4:12 PM by Unknown

Computer books come in all sorts of flavors. There are textbooks, users manuals, reference works, etc.

This short book by David Agans doesn't fit easily into any of the common categories: Debugging: The 9 Indispensable Rules for Finding Even the Most Elusive Software and Hardware Problems.

Debugging is one of those funky parts of the programming profession that doesn't get talked about very much. I'm not sure why that is, because it's quite clear to me, after three decades of programming, that debugging skills are one of the crucial characteristics that distinguish successful programmers from failed ones:

Successful programmers are able to debug programs, whether or not they wrote them initially.
I've seen a lot of people who wanted to become programmers, and failed, and in many of those cases the part they struggled with was debugging. They could write programs that were quite clear, well-designed, neatly-expressed.

But no program ever works correctly the first time; as the great Donald Knuth said: "Beware of bugs in the above code; I have only proved it correct, not tried it."

So, to be a successful programmer, you have to learn how to be successful at debugging.

Many programmers think that debugging is some sort of magical ability; either you have it, or you don't. I don't think that is true; I think you can learn debugging skills, and, much more importantly, I think you can improve your debugging skills.

Agans's short, fun, highly-readable book is a great way for you to learn or improve your debugging skills. Here's what Agans says about the goal of his book:

In this book I'll introduce the nine golden rules of debugging, then devote a chapter to each. I'll start each chapter with a war story where the rule proved crucial to success; then I'll describe the rule and show how it applies to the story. I'll discuss various ways of thinking about and using the rule that are easy to remember in the face of complex technological problems (or even simple ones).

The rules themselves are online, at Agans's web site, and they are nice and short and to-the-point:

  1. Understand the system
  2. Make it fail
  3. Quit thinking and look
  4. Divide and conquer
  5. Change one thing at a time
  6. Keep an audit trail
  7. Check the plug
  8. Get a fresh view
  9. If you didn't fix it, it ain't fixed

You can get a sense of Agans's light and slightly tongue-in-cheek style as you read the rules, but in fact I like all his rules and think they're great.

If I could add one rule of my own, it would be:

Don't be afraid to try something.
I see so many people get stuck in debugging where they know there's a bug, and they can reproduce the bug, but they don't know what to do next. When I see this happen, I say to them: "what have you tried?"

Often, just asking them what they've tried gets them going again, but other times people are paralyzed by a fear that changing something is going to make matters worse.

Well, it might. But, you can't let that stop you from at least trying something. It may not be the right thing, but try it, and you'll learn from your experiment, and that will help break the paralysis.

Anyway, regarding Agans's book, I was pleasantly surprised: even after 30 years of experience, I found it a rewarding read, and I recommend it to anyone who's considering spending a significant portion of their life as a computer programmer.

Email ThisBlogThis!Share to XShare to FacebookShare to Pinterest
Posted in | No comments
Newer Post Older Post Home

0 comments:

Post a Comment

Subscribe to: Post Comments (Atom)

Popular Posts

  • Shelter
    I meant to post this as part of my article on Watership Down , but then totally forgot: Shelter In Shelter you experience the wild as a moth...
  • Parbuckling
    The enormous project to right and remove the remains of the Costa Concordia is now well underway. There's some nice reporting on the NP...
  • The Legend of 1900: a very short review
    Fifteen years late, we stumbled across The Legend of 1900 . I suspect that 1900 is the sort of movie that many people despise, and a few peo...
  • A Very Short Review of The Hangman's Daughter
    By way of the quite-nice Kindle Owners Lending Library , I recently read Oliver Potzsch's The Hangman's Daughter . At least part of ...
  • Jones v Anand
    If you think grandmaster chess is boring, with lots of positional strategic maneuvering, you owe it to yourself to play through the game bet...
  • A Glorious Defeat: a very short review
    Somewhat unexpectedly, Timothy Henderson's A Glorious Defeat: Mexico and Its War with the United States found its way to my nightstand....
  • Unbroken: a very short review
    Laura Hillenbrand's Seabiscuit: Three Men and a Racehorse was a massive worldwide hit, and became a movie hit as well. It took her seve...
  • One Day: a very short review
    I'm about two years late (typical), but I finally got around to David Nicholls's One Day . The book's concept is to tell a story...
  • Rim fire winding down
    I hadn't been over to Inciweb's Rim Fire status page in a while, so I dropped in to see how the progress goes. This is the long, sl...
  • XCOM Enemy Unknown
    I don't have much time to play video games, so I tend to go many months between games, looking for just the right one. I've been pla...

Blog Archive

  • ▼  2013 (165)
    • ►  September (14)
    • ►  August (19)
    • ►  July (16)
    • ►  June (17)
    • ►  May (17)
    • ►  April (18)
    • ►  March (24)
    • ►  February (19)
    • ▼  January (21)
      • Ora et Labora: a very short review
      • Cloud Computing reading list
      • Here comes the sun!
      • A patient departure
      • One Million Square Feet
      • Debugging: a very short review
      • Northern California Perfection
      • Stuff I'm reading this weekend
      • Jeff Hodges on distributed systems
      • Overseas Reymar
      • Statistical evidence of fraud
      • Kingdoms of Amalur: Reckoning: a very short review
      • Tata Steel 2013 has begun
      • Aaron Swartz
      • Greatly exaggerated rumors
      • Virtualization
      • Performance behaviors can be very non-linear
      • SHRDLU is wrong!
      • How Complex Systems Fail
      • Computer programming remains the province of experts
      • Happy New Year!
  • ►  2012 (335)
    • ►  December (23)
    • ►  November (30)
    • ►  October (33)
    • ►  September (34)
    • ►  August (29)
    • ►  July (39)
    • ►  June (27)
    • ►  May (48)
    • ►  April (32)
    • ►  March (30)
    • ►  February (10)
Powered by Blogger.

About Me

Unknown
View my complete profile