O'Reilly logo

Effective Debugging: 66 Specific Ways to Debug Software and Systems by Diomidis Spinellis

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

5. Programming Techniques

As a developer, most failures you’ll encounter are likely to be associated with the software’s code. One method to find the corresponding fault is to stare the code sternly in the eye—with some help.

Item 38: Review and Manually Execute Suspect Code

You can often pinpoint a bug in an algorithm by examining the code or executing the corresponding lines by hand. You want to verify that the code is written correctly and that your understanding of the code is sound. If you find an error while you examine the code, you’re done. If not, you can then execute the same code with a debugger (see Item 29: “Step through the Code”) and see where you disagree with the computer.

On your first pass through the code, carefully examine ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required