“You’re doing it wrong” is probably one of my favorite phrases in the English language. It’s a phrase that upsets a lot of people, coming across like an insult and bruising the ego. People often feel a need to defend themselves or their ideas when they’re told “you’re doing it wrong.” Those four words can sour a perfectly good mood.
But for me, the phrase implies a learning opportunity. If I’m doing something wrong, that means that there’s a (presumably) better “right” way to do things. If I’m doing something wrong, I would rather someone tell me about it (and risk bruising my ego a little) than continue being wrong.
I’ve been learning how to use Test-Driven Development to make my code cleaner, more stable, and more manageable. But today I learned that my approach to TDD was wrong, and that I was testing things that I shouldn’t test, and missing things that needed testing. Not only that, but I had actually adopted a poor design strategy in some cases, doing things in a manner that would cost me more time and effort in the long run.
Thankfully, the individual who called me out was willing to provide guidance. We talked for three hours, and I learned a fantastic amount in the process. Thanks to his help, I not only learned about my bad habits, but about how to correct them as well! In the process, I realized that I’m going to have to re-write a significant part of my code (if not the whole project) in order to do things the right way – a task that will take a significant amount of time. Which seems like a bummer… But in the process, I’ll learn new skills, improve my code, and develop better coding habits for all of my future projects.
All in all, I’d call that a win.
So please, if you ever see me making a mistake… Don’t be afraid to say “you’re doing it wrong.”