Are you running into problems with some code on your webpages wondering what could be wrong even though you inspected it and everything seems ok? Are you thinking this might happen? (if it hasn't happened yet?). There are many errors that can come about in code, and fortunately, many ways to find and fix them.
Debugging has been around as long as writing code has been around. It is an essential skill for you to have as a web developer.
This tutorial focuses on:
- Origin of the term 'debug'
- Debugging is for everyone
Origin of the term 'debug'
'Debug' in the world of code literally means to find and eliminate errors. Why don't they just call it 'finding and eliminating errors'? Well, that's a little to long, something shorter and catchier was needed!
There is actually some controversy as to how the term 'debug' originated. What you choose to believe is up to you.
The popular opinion
A navy admiral named Grace Hopper was having problems with her mainframe computer. She opened up the computer and found a moth in it that was preventing it from working properly. After pulling out the moth and making the computer function normally again she claimed the computer had been "debugged"
Computers originally generated a lot of heat and because of this attracted a lot of bugs. The bugs would make the computers malfunction and cleaning them out of the computers made them function properly again. Once the bugs were cleaned out, the computers had been "debugged"
Debugging is for everyone
Everyone that writes code will run into errors (yes, everyone). You are after all, a human and you will make mistakes. And it's ok if you do, but it's how you react to those mistakes that counts.
This section contains lots of information that will help you become a great debugger!