HACKER Q&A
📣 Traubenfuchs

How to get into algorithmic thinking and leetcode?


My company looks like it‘s dying and I want to hunt for a new job or at least become interview ready enough, in case push comes to shove.

I can build you scalable CRUD apps from https ingress/terminator to dockerized HAProxy/nginx/traefik api gateway to ouauth2 protected spring backends using SQL/redis/bigtable/s3/sns/sqs and despite not ever having been a frontend developer, I probably know more about angular, JS and browser quirks than your average frontend junior. For my bachelor thesis, several years ago, I developed a simple react native app. I am a backend dev for 11 years now, but also a jack of all trades. I feel ready to talk about application/system/solution design/architecture.

I also like to write documentation, talk to third parties and engage in requirements engineering. You can confidently leave me alone with third party partners. I have done hiring and interviewing. I hold a MSc and worked at two companies you have heard from, one of which produces applications you probably came into contact with.

Yet I can‘t solve any easy leetcode problems. If I can, then maybe the n*n brute force solution. Medium and hard problems? Absolutely impossible. Any work on it gives me severe anxiety, which makes even dumb memorizing solutions hard. I love programming, but I hate algorithmic thinking, algorithms and puzzles. With a passion. At least I can do fizz buzz...

Do you have any input for someone like me to become competent with leetcode?

Anyone else in this predicament?


  👤 hayst4ck Accepted Answer ✓
Viewing this question abstractly, you are asking how do I get better at ?

The answer is the same. Progressive load. Do something that you struggle with but can complete until it is no longer a huge struggle, then do something harder, progressively. Both biting off more than you can chew and not biting enough will prevent progress.

The key thing to understand is that the feeling of struggle is exactly the feeling of learning, particularly for older people. The feeling of struggle is not metaphorically, but physically the precursor to learning. The feeling of struggle is marking brain cells to be altered during sleep (layman's translation of huberman podcast) which is when your brain actuates learning. So you must seek the feeling of struggle to be learning.


👤 throwaway0asd
Leet code is like prostitution. It’s cheap, short term, and the employment prospects are high risk / low reward.

In most of software there is no relation between being a good developer and being either highly valued or highly employable. Being good requires lots of practice solving tough problems. Being highly employable means high familiarity doing average things with tools incapable of solving tough problems.


👤 usgroup
I’d suggest perhaps finding a more senior colleague that can work through a few questions with you just to try and identify where your problem seems to be.

However I’d suggest that being able to write and analyse algorithms is more than mindless tick boxing — it is essential to backend beyond plumbing, so I personally think it’s an investment.


👤 gigatexal
A video-games dev told me to do Advent of Code instead of the hackerrank/leet-code nonsense -- it'd make me a better programmer that way. I dunno. You can do productive work but hiring is still about solving ridiculous things.

👤 dmillar
1. Keep doing LC easy until they are easy, read and re-read comments and solutions until it sticks. You can get it, but it will take work.

2. Even though you have MSc (in CS or similar I presume) go back and do an algos class on coursera (or similar).


👤 sargstuff
Perhaps focus in a given area/subject.