Debugging, in computer programming and engineering, is a multistep process
that involves identifying a problem, isolating the source of the problem and
then either correcting the problem or determining a way to work around it. The
final step of debugging is to test the correction or workaround and make sure
it works.
How debugging works in software
The debugging process starts as soon as code is written and continues in
successive stages as code is combined with other units of programming to
form a software product. In a large program that has thousands
and thousands of lines of code, the debugging process can be made easier by
using strategies such as unit tests, code reviews and pair programming.
Common coding error examples
Some examples of common coding errors include the following:
Syntax error
Runtime error
Semantic error
Logic error
Disregarding adopted conventions in the coding standard
Calling the wrong function
Using the wrong variable name in the wrong place
Failing to initialize a variable when absolutely required