A regret maximization framework

A regret maximization framework

How to be regretful for software engineers
Published September 16, 2023


My regret maximization recipe
  • Specializing prematurely by going with the flow
  • Cracking LeetCode to let the market decide what’s best for you
  • Learning Vim to impress others
  • Avoiding examining your beliefs
  • “It can’t be my fault.”

Following the footsteps of the legendary investor Munger who delivered a speech about how to guarantee a life of misery, I’ve stumbled across the formula for a career of regrets. I had my skin in the game, i.e. 5 years of continuous mistakes backed by ignorance and folly, to assure me its effectiveness. If you’re looking for a recipe to minimize regret, stop reading here and consider forwarding a resume to Jeff Bezos instead.
Let’s debrief how my regret maximization framework works.

Going with the flow

Earlier in my career, I made the mistake of specializing too soon. I won't delve into the broader debate between specialists and generalists here, but a tweet by @Patio11 encapsulates it well. I got introduced to React and Node.js during my first internship and quickly became pigeonholed into frontend web development.
At meetings, our roles often define us more than our names. And these designations, displayed everywhere from employee portals to LinkedIn profiles, shape our work identities. If we don’t set our own course, our environment will.
Specializing quickly sets a self-reinforcing cycle in motion: you become known for a skill, get more tasks related to it, and rapidly become an expert. It’s great for productivity, but not always for personal growth or satisfaction. I learned the hard way that simply not disliking a role isn’t the same as truly loving it.
This late awakening can be attributed to a lack of self-accountability in determining what truly matters to me, leading to a default 'going with the flow' mentality and causing lots of anxiety and mental sufferings.

Money, not your heart

No doubt money is important. But software engineers are paid quite generously in the US and many other places. Once you cross certain income threshold, you reach a point of diminishing returns where other psychological factors kick in and become substantial to your drive.
I had a weird relationship with LeetCode - an online technical interview preparation platform. When it comes to cracking a coding interview, I doubt if there’s anything more effective than practicing LeetCode. But it’s a rather contentious take.
Many people simply can’t accept the fact that a brilliant hacker could fail a Google interview because of not knowing how to reverse a binary tree. I’m one of those people because it reminds me of the old days of memorizing textbooks to pass exams in China. It’s a misfortune when we’re trapped in a rigid system like this, all under the guise of identifying talents (by rejecting real talent).
Despite my contempt about the LeetCode style technical interviews, I still used the platform to prepare my interviews before. I can’t find better reason other than peer pressure and survivorship bias prevalent on the internet. Many share success stories of hopping between jobs to secure higher salaries, creating pressure to follow suit.
However, every time I tackled these coding questions, an inner voice questioned, "What on earth are you doing with your life, wasting it on these mechanical problems?" I found no excitement in solving them. Even when I received job offers, I didn't feel proud. It's a peculiar feeling that not everyone can relate to. It raises a fundamental question: What's the purpose of pursuing something that neither your current nor future self enjoys?
To be fair, LeetCode does deliver on its promise as an interview preparation platform. However, the value you derive from it depends on how well it aligns with your personal values. For those whose values don't align with the current interview system's emphasis on algorithmic challenges, I suggest not sacrificing your peace of mind if money isn't your top priority. Instead, let your heart guide your actions, not the market.
You'll find much greater happiness by staying congruent with your values.

Impressing others, not yourself

As we step out of school and into the professional world, we often find ourselves standing on a blank slate with limited knowledge about the chosen field, yet surrounded by lofty expectations. We don’t always recognize the insecure novice within us, but we do see the need to outshine our peers. After all, who wants to be viewed as an imposter?
This was the backdrop of my early career, and I felt compelled to take action. I decided to emulate what I believed many great programmers would do - I embarked on the journey of learning Vim (apologies to Emacs enthusiasts), a text editor beloved and crafted by hackers. I was convinced that this was the path to greatness.
The learning curve is a bit deep but that’s to be expected for taking “the road less traveled”. The allure of dancing on the keyboard shortcuts was addictive, and I poured countless hours into refining my vimrc file, much like a musician fine-tunes their instrument. Besides, the motivation isn’t grounded on personal growth, but rather a desire to impress others.
It was a humbling realization that the connection I had drawn between great programmers and the tools they used was completely flawed. I did not emerge as a Vim guru or a superior programmer. The delusion of superiority driven by personal preferences is, to put it mildly, counterproductive. Falling into the vanity trap of constant comparison distracted me from the actual work needed to improve my craft - skills earned through the sweat equity.

Don’t examine your beliefs

Companies often establish guiding tenets like "Own it," "Do the right thing," or "Have Backbone; Disagree and Commit" to aid decision-making. These principles ring true because they can be interpreted in various ways.
However, it's crucial to realize that corporate values don't necessarily align with your personal values. Merging them into a single mix can create problems.
  • Do we genuinely want to take ownership of numerous tasks that no one else cares about, not even ourselves?
  • Are we certain that penny-pinching on things that boost our productivity is the right course of action?
  • Should we automatically oppose a colleague's opinion without first understanding the basis of their arguments?
I recall a friend who worked for a major tech company. He joined as a recent graduate, facing the common dilemma of navigating a new job. However, the company had a tenet that encouraged every employee to embrace ownership, aligning perfectly with his personal values. Consequently, he accepted every work request that came his way.
The result? He became the designated owner of the team's on-call ticket queue, a repository of operational tasks that experienced colleagues shied away from. Despite this, he perceived tackling these tickets as a sign of productivity and excellence in his role. Additionally, he received positive feedback from peers for his ownership.
However, his performance review told a different story. This disconnect between positive peer feedback and managerial evaluation prompted him to question what had gone wrong. He had always been lauded as a responsible student and friend before.
Dealing with workplace issues is challenging, but even more so is accepting that a belief, once beneficial, may become outdated. Understand that every belief is context-dependent and warrants careful examination before becoming a part of your identity. Beware of fruitless debates like determining the best programming language, framework, or IDE. When we attach our identity to tools, we risk losing sight of the actual problems we're addressing.

A victimhood mindset

This is the most powerful force that can counter all of above. By putting on this armor, no challenge or setbacks could ever approach us. Under its influence we’ll be rewarded with no self doubt, no responsibility, no rationality and so on.
I couldn’t be more familiar with this, here are some examples I draw from personal experience:
  • Automated build failed? Flaky pipeline.
  • Bug reports piling up? Go talk to the QA.
  • Missing a deadline? Software is inestimable.
  • Career ceiling? Favoritism.
  • Disagreement with management/PM? They got no technical background.
  • And the list goes on…
The common theme is clear - It’s always someone else’s fault. And the situation never improves; only getting worse. The resentment accumulates, the morale plummets, and eventually, the only viable choice seems to be leaving the place.
But why leave? Because it’s the toxic working environment’s fault.
We will embark on a new journey, after a short honeymoon period, the same vicious circle repeats itself. I don’t know where exactly you’ll end, but in my case, it culminated a career collapse that marks the pinnacle of my regrets.

Conclusion: steering clear of regrets

To summarize the key points I've shared:
  • Going with the flow results in a career scripted by external forces.
  • Prioritizing money over your passion leads to inner conflict.
  • Focusing solely on impressing others leads to a depletion of motivation.
  • Neglecting to examine your beliefs risks squandering your efforts.
  • Embracing a victimhood mindset can make you feel invincible, but it's a perilous illusion.
I’ve testified above rules under different circumstances with reproducible regrettable outcomes. Maximum regret is achieved when all of them combined in synergy.
However, I genuinely hope that no one has to go through this because it's an unpleasant experience. In parting, let me leave you with another quote from Mr. Munger:
“All I want to know is where I'm going to die so I'll never go there.“