Better HN
topnewbestaskshowjobs
Log inSign up

nhoe98thnuoe

6 karma · joined Jul 11, 2018 (8y ago) · 2 submissions

Submissions

comment 8y ago · link · parent

In my opinion the reason that debugging isn't treated as a first-class activity is that it isn't taught at all in schools. Or at least it wasn't when I was in school. We were given about 2 sentences that said, "the debugger is at /usr/bin/gdb. It can help you step through your code to find a bug." And then we were thrown to the wolves with what is arguably one of the worst debuggers in the world with no documentation and no help.

comment 8y ago · link · parent

This is known as regression testing, and it's extremely useful. For example, you find some bug where, say, a calculation produces a nonsense result. You fix it, then add a test for what you just fixed. 2 years from now, someone refactors the code and reintroduces the bug because their refactor didn't take into account all of the possible input cases. Your test now catches it.

Our regression tests have literally found hundreds of bugs over the years and saved us a lot of time and embarrassment.