Been grinding leetcode for the last 2.5 months, where I study 1-2 hours a day every day. Have only completed 60 so far (36 easy 17 medium) + 7 on Grokking. The reason it's so little is because I would spend a week on each topic trying to understand what it even is via YouTube videos before attempting related/topic tagged questions. From a conceptual standpoint, most of these topics make perfect sense. Graphs and trees make sense as does bfs/dfs through recursion on them. LinkedLists also make sense, with their next pointer. Dictionaries with their key/val. Binary search with the midpoint, low, high. Sliding window for subarrays. Lists/Arrays I've know for years as have most developers. And so on. Problem is that although I understand these concepts I still fail at solving most of these problems. The applications of these concepts is always so varied and it almost seems like there are tricks to most of these problems that are unique. Most of the 60 that I 'solved' I would look at the question and often have no idea where to even begin. Sometimes I would make an attempt and fail miserably. Rarely would I be able to solve it, and I can count on hands how many would run on first try (rarely optimally). In the cases where I can't solve I end up looking at the solution in the discussion, sometimes understand it and if not then watch YouTube video for that particular problem to understand it. Then implement it. But it seems like I'm just short-term memorizing some trick, and even when I do a 'related' problem I do not know how to solve it since 'related' is often not so related. Also I'm not sure if the solutions I'm implementing after looking are sticking in memory. Am I going about studying wrong? What would you recommend I do differently? Should I change my approach? #leetcode #interview #studying #software TC: 120k
60 is nothing, of course you keep failing. It’s not easy keep going
This is a very long post. Pls cut the topics section where you talk about bsearch linked lists etc. you dont get better at lc by understanding topics. You get better at it by solving q’s. 60 is literally nothing. Dont spend too much time in watching videos. Keep solving qs.
It requires some IQ or logical thinking, if coding is not your forte or interest, it is hard no matter how much effort u put in, that why some people got high TC but not all
Do some mock interviews with a friend or online, it’ll help you tighten up on concepts and think of an approach before even starting to code it out. Keep a spreadsheet or github on questions you’ve done and review approaches.
Try to be brutally honest about what you understand vs don’t. Don’t stop working on easy problems until you improve. Otherwise you’ll get burnt out for trying harder problems without understanding the fundamentals. Ideally the problems you work on are hard enough to where you are learning, yet easy enough to solve.
On top of watching videos to understand these problems, after you've gathered your thoughts, try to write down the algorithm without looking anything up. Try to go through the problem one step at a time and understand what each part of the algorithm is doing, and how it attributes to solving the full problem. You'll likely find a pattern in many algorithms that can be applied elsewhere, and eventually you'll have your mental toolbox by your side. It's just a matter of selecting the correct tool for the job when looking at a problem.
Don't rush through topics. Build up an understanding of a topic and filter in LC by that topic and solve 10 problems under that topic and move on to the next one. Try to work on related topics together: For eg trees and linked lists, stacks and queues etc. Array problems may be hard because there are so many variants of them. Practice will help here. Try out this for a list of practice problems for each topic https://yangshun.github.io/tech-interview-handbook/best-practice-questions
India
14h
2849
Why is it so G*damn difficult to move money out of India
Tech Industry
16h
274
Working on a project you don’t like or working with someone who you hate?
Tech Industry
8h
423
How’s capitalism going?
AMA
Yesterday
2996
I have worked at TikTok US core tech for 3 years. AMA.
Ask Blinders
19h
857
Why Pronouns shit captured US ? I don’t see this anywhere else
Same goes here evern after grinding for nearly 2 years