From the course: Debugging in C#

Unlock the full course today

Join today to access over 22,700 courses taught by industry experts or purchase this course individually.

The debugging process

The debugging process

From the course: Debugging in C#

Start my 1-month free trial

The debugging process

- [Instructor] In debugging, we usually have a strategy for tackling and fixing bugs. We don't just go into the code and start changing a bunch of stuff. The hardest bugs to fix are the ones you can't find, because if you can't find it and understand it, you can't figure out how to fix it. This means the first step in debugging is often reproducing the problem. Once you can reproduce the problem, you have access to the problem and can dive in for more information. Next, if you are the person that has found a bug, try to describe the bug in as much detail as you can. Explain what the given input was, what the output, and what the output should've been. Sometimes, you may find the bug, but it's in a different part of the program, and someone else has to fix it. This means detailing the error as much as possible is extremely important. If you are the person debugging the program, then you'll need access to the source code. The next step is to create a snapshot of where the bug appears in…

Contents