Debugging Sherlock Holmes and Dr. House Style

The psychology of computer programmers is interesting stuff. The classic view of a programmer is someone who sits around creating all day like an artist or writer. It’s a creative job, trying to be the next Bill Gates. The reality is that the most spend a significant amount of their time diagnosing problems and debugging. That includes analyzing bug reports, tracing bugs, finding solutions, implementing, and testing. In practice this part is much more detective than artist.

After years of observation, I’ve come to the conclusion that most good programmers bare a striking resemblance to both Dr. House, and Sherlock Holmes (whom the Dr. House the character is partly based upon).

Overlapping Traits

  • Reluctance to accept cases they don’t find interesting – Both Dr. House and Sherlock Holmes hate cases that they aren’t interested in. Programmers always gravitate towards bugs that interest them, and shun bugs that don’t. Very few will even attempt to dispute this.
  • Otherwise lazy – When not solving something that interests them, they are what most would call lazy.
  • “Rubik’s complex” – Obsession with puzzles.
  • Reliance on a related science – Dr. House and Sherlock Holmes rely heavily on Psychology. Programmers gravitate towards user experience which Wikipedia defines as incorporating “psychology, anthropology, computer science, graphic design, industrial design and cognitive science”. Coincidence?
  • Substance dependence – Dr. House prefers Vicodin, Morphine and Sherlock Holmes went for Cocaine, Morphine. For programmers it’s often an extraordinary dependency on caffeine that keeps them going.
  • Overconfidence to the point of arrogance – I don’t think any further explanation is necessary. Programmers are as arrogant and defensive on their work as Dr. House and Sherlock Holmes are about their diagnosis/solution.
  • Introvert – Both Dr. House and Sherlock Holmes are introverts. So are many/most programmers.
  • Strong deductive reasoning skills – The best programmers are the ones who can analyze a bug report and using knowledge of the application and related technologies can diagnose the problem with accuracy that surprises even those with many years more experience.
  • Use of alternate names – Holmes and Dr. House call people by their last names. Programmers have this habit of using network names, usernames, IRC nicknames.
  • Showmanship for their skills – Dr. House diagnosed a waiting room full of patients in about a minute with surprising accuracy without meeting with each patient. Sherlock Holmes has a love for elaborate traps to show off. Programmers love to show off. That’s why so many blog. Accomplishments are the rare things they willingly document.

Slightly higher occurrence of the following personality traits may apply: “moody”, “bitter”, “antagonistic”, “misanthropic”, “cynical” “grumpy”, “maverick” and a “curmudgeon”.

Sherlock Holmes

Sherlock HolmesThe most distinct Holmes trait is that he refused guessing or theorizing before having the necessary clues or data to reach a conclusion and solve the case.

Programmers who fall in the Holmes party refuse to make guesses without seeing some evidence and immediately tries to reproduce the bug and starts tracing to gather data. Once there is a mountain of data they start to deduce the problem and the solution. Once they reach a conclusion they will break it down into a very concise deductive argument.

Pipe smoking is optional.

Dr. House

Dr. HouseThe most distinct part of the House approach is the willingness to make an educated guess based on limited information.

Programmers who fall in the House party are willing to make guesses early on and immediately start debugging in very calculated parts of their code base. As they come to realizations and learn new information they are willing to adjust or completely abandon their former approach and go with a new hunch.

They often find themselves soliciting ideas from others and using good ones however they almost enjoy shooting down ideas as invalid based on their skills and knowledge.


I’m pretty sure there is no “better” approach. It’s just two different ways of going after a problem. It’s completely possible to be a hybrid. I think it’s more of a spectrum of personality and technique.

7 replies on “Debugging Sherlock Holmes and Dr. House Style”

@Majken: Well aware, though I think for most individuals it generally falls closer to obsessive-compulsive disorder than Asperger’s. The most glaring difference is the repetitive patterns generally aren’t as prominent and the impact on interpersonal relationships. Of course that varies per person.

I don’t actually think arrogance is characteristic of good programmers. Good programmers know just how little they actually know and how easily they can make errors. They recognize and respect the extreme complexity of what they craft, and they know that perfection in all but the simplest cases is unattainable except at extreme expense.

Of course, you forgot to mention House’s most distinctive characteristic: complete disregard for morality or any form of professional ethics. Most people, in most professions, thankfully lack this characteristic. (Most people aren’t surrounded by such extreme enablers as House is, either.)

@Jeff Walden:

I’m not (necessarily) suggesting all traits listed are what make programmers good. Some are, some aren’t. I’m just noting they are common traits. Of course what one person interprets as “arrogance” is to someone else “confidence”.

Regarding “disregard for morality or any form of professional ethics”, that’s also a gray area. Part of that is simply if your end-game focused, or procedure focused. Do the means justify the ends, and to what extent can you go? One can also argue that standing idle and letting rules and *** (or Arse)">CYA policy kill a patient is immoral and unethical. For example people have argued for years if there is such a thing as a “white hat hacker” or just criminals who acts as a mercenary. IMHO most white hat hackers are legit, but that’s hardly a universal feeling.

Reserch : Several people are (and was) Sherlock Holmes in reality : look at their common points

–»Study their biography, they all have these common points :

To Sherlock Holmes, it’s criminology.

–»they are so conscious of reality they can not lie to themself, they accept their death as naturally as their life

They died : To Nietzche, i twas philosophy and poetry. To Mozart and Jimi Hendrix and John Lennon, it was music. To Claude Rifat, i twas conscious dreams. To Henry Blake, i twas horses. To Mother Theresa,itwas love, to Jesus too. To Vincent Van Gogh, i twas peint.

–»they live intensely « me-here-right now », never let others control their mind. And they have so much to give.

They are alive : To Shaun Ellis and Helen Jeffs, it’s wolves. To Lydia Renoir (alias Johanne Verdon) it’s novels and she’s also a naturopathe clinician. To Patch Adams, it’s medecine. To Michel Lauzière, it’s creation of musical instruments. To Jill Pruetz, it’s primatology. To Lynn V Andrews, it’s Amerindian shamanism.

–»People think it’s genius or exceptionnal. But we all can do what they do if we become aware that’s worth fighting for.

Leave a Reply

Your email address will not be published. Required fields are marked *