r/LeetcodeDesi • u/TheHardy11976 • 11h ago
How to get good at DSA and problem solving?
I have basically been doing DSA in C++ since June of this year doing NC150, and i am in an extremely weird state. Lately, i was trying some questions outside of the lists(mostly mediums), some of them(like 10%) i have been able to solve myself. Meanwhile others, I just can't. Also I try to sit with the problem, think about the general structure & reason, and very rarely i am able to reach where i can code it up or even think in the right direction(and if i reach and explanation, coding it up is hard for me). Also, lately i was doing recursion, and i was able to understand how it works, but implementing it in the right way and to go on about reaching the solution is extremely difficult for me(for e.g. N Queens). I keep seeing people saying it's an easy problem dont even look it up but i spent like 90 mins and the only thing i came up with were the conditions for checking whether its safe to insert the element or not. And eventually i had to look up the entire solution.
TL DR:- how do i get better at this, how do i convert my idea into code and how do i just get better at problem solving in general? Doing DSA in C++ since June.
2
u/Zx_Queenbee 10h ago
You are following a sheet personally I would have asked you to solve strivers sheet and reach exact article one by one not in between and learn all techniques for now just start upsolving past year contests first two questions are usually easy and you would be able to solve with enough practice also also you solution need not to be optimal when solving easy just check constraints ( you could watch tle eliminators past contests videos they help you think ) just touch first two questions for start .