Why do you write to console instead of using a debugger?

Note: When I find bugs, I put them outside, in the garden, instead of killing them; bugs are people too.

It can be painful to watch me troubleshoot without a debugger. Colleges have encouraged me to "get a real IDE."

So, why do I not use a debugger? Thoughts, off the top of my head:


  • have their place in my workflow
  • can be time consuming to set up
  • are IDE specific; my step one in a code base is not "install this IDE," and my ability to troubleshoot on other's computers is important

Console Logging

  • is a hard to learn skill
  • is important when we need it most and lack access to a debugger (e.g. emergencies)
  • works easily with async and concurrent code (does not change time)
  • encourages a scientific, hypothesis-test approach to understanding the code base (this is my most important reason)

Those are my ideas. A few other programmers think similarly. E.g. Uncle Bob (Robert C. Martin) once wrote this:

IMHO a debugger is a tool of last resort.

That's pretty much how I see it. Breathless, exasperated, the humble developer looked at his pairing partner, "Okay. Let's bring out the debugger."