The most common answer when you ask a professional about how to solve a specific problem is: it depends. I find myself regularly in this situation when I talk to craftspeople about home renovation projects. I can understand how frustrating this can be for the less experienced person asking the question. When I’m the one to say those two words, I try not to say them but explain what I think it depends on instead. But more often than not, I find this pretty hard to do. Why is that?
There rarely are one size fits all solutions for certain types of problems. While less experienced people tend to think that finding solutions to problems is like solving an arithmetic problem, A + B = C, more experienced professionals know that neither A nor B are fixed and there often is an unknown X.
What Does It Depend On?
That’s the big question. A professional, given a particular situation or problem, will quickly determine the variable factors that they need to consider when coming up with a solution. But how do they do this?
One of the best Age of Empires II players in the world, when asked if he has any tips on how to get better at the game, gave the following answer:
Try to learn the reason why it depends. [...] The trick [...] is to understand why it depends. Once you know that you can start to learn more.
Knowing what it depends on is hard to explain or teach because it is a lot about gut feelings. Decisions are not always made based on hard facts. Even when we think they are. We tend to betray ourselves. More often than not, the gut feeling comes first, and only then the newer parts of our brain come up with a coherent story to rationalize our initial gut feeling. Our brain recognizes some pattern it already has seen a thousand times, and it immediately provides us with a solution to the problem.
There is no single secret piece of knowledge that somebody can teach you to become a professional yourself. I can’t tell you 5 Simple Tricks to Becoming an Expert Developer. Understanding why something is right in one scenario but not in another comes with experience. Being bitten by not considering X or not planning for Y. Having seen many different kinds of bugs. Watching hundreds of conference talks and reading thousands of blog articles, often providing contradicting information. All of this adds to make you a better developer in the long run. It all trains the pattern recognition part of our brain.
Wrapping It Up
Reading a lot, soaking up a lot of knowledge, that all helps at becoming better. But there is nothing anyone can teach you to catapult you from junior level to an expert developer level. Becoming an expert in any profession means that you’ll start feeling what’s the right thing more than knowing it. This might sound crazy in an area like programming where everything is about logic. But always remember: There Is No Spoon.