I am solving/upsolving the medium tagged questions from leetcode company wise (fb, google, uber). I find it difficult to come with a solution (with code) even in one hour, if I haven't seen the problem earlier. What is wrong with me? Is this natural or I need to upsolve the problems and see and the. only can expect to solve those in 25-30mins? Please help/suggest. upsolving-seeing the solution and coding it up YoE- 3.5yrs TC- 24LPA India #faang #uber #fb #google #leetcode
Not to brag, but I face serious difficulties doing hard LC only. It's possible to face difficulty in medium LC if you are rusty, but practicing for a week or so should bring you back on track.
Op , how many easy problems have you solved? Maybe you got out of your range too soon.
This is ok, the more you struggle the better you will become.
Some of those mediums should be rated hard, I donāt blame you
yaaa exactly.. its just I feel 40% of them are way too difficult to understand.
My experience was that I got better at LC medium with time. But I am yet to cross the LC hard curve. At this point I am not even sure if I can ever get better at LC hard
Agreedā¦ i have done around 530 problems till now but the LC hards are still too hardā¦i can maybe solve 1-2 out of 10 within the time limits(45mins)
If you cannot get at least some intuition in your mind about how to solve a medium problem rather quickly, then you're not matching your experience to previous problems well. This definitely means either youre lacking on practice, in which case you just need to crank out more and more problems, or youre lacking an understanding of the problems you have solved in the past, in which case you should deeply study the concepts related to whichever problem you're solving. On LC the problem will have tags, and so you can research other problems of that type before attempting to solve the LC, and learn about the strategies for that type of problem, and then solve it. Knowing what type of algorithm, data struct Goes for what problem takes practice though after your develop your understanding
Classifying problems on pattern they follow also helped me a lot too. Aka sliding window, two pointer, bfs/dfs/backtracking, etc you get the gist
Try doing problem chains. That is after solving subsets do subsets ii and so on. You can find similar problems in the bottom of LC page. Also solve each question with intent
you might also want to learn the concepts via a book, course, or video series. things really make sense once you sharpen the knowledge that the questions are based on.
What I have observed is with some decent practice and by uncovering standard patterns you would be able to do the mediums. The hard ones are a bit devilish so I only do the most frequent and popular ones ( one should do them).
OP, please make it a poll, I believe the same is case with many people. I'm in same boat as you
By poll, I mean add options like 1) in same boat 2) Leetcode hard is easy for me Etc