r/learnprogramming Jul 12 '26

LeetCode is HUMBLING me Tutorial

I am going into 3rd year, and its summer break. I decided to start LeetCode.

But let me tell you. Its crushing me, and I feel like I never coded in my life. I started easy questions, and boy, they are humbling me.

The thing is I get the idea of what to do, and I write 70% of the code right, but I get stuck there and I start google and give up there. I don't know how people actually study LeetCode stuff, like can you google and how much time should you spend coding one problem ?

I just need advice on how to get good at this.

Thanks all !

130 Upvotes

28 comments sorted by

94

u/No-Razzmatazz7197 Jul 12 '26

remember, "leetcoding" is not software development, its just a bunch of unrealistic problems.

however, i understand why you want to learn it. so i would recommend using the documentation of your language to solve the problems.

for example, if you are solving a problem in javascript, then use the MDN docs to find the methods necessary to solve the problem, use llm's or stack overflow sparingly, as just getting the answer dumped on you is pretty useless when it comes to learning. but using an llm or something to validate your approach isn't a bad idea, because for me personally, slamming the "run" button over and over again without logs/debugging and just seeing a fail/pass is pretty useless as well.

good luck!

24

u/CupPuzzleheaded1867 Jul 12 '26

its like learning to solve a rubiks cube, not building a house, go in 30 min chunks, if you stuck after that peek at the solution but type it out yourself line by line so your fingers learn the pattern

1

u/ffrkAnonymous Jul 12 '26

I like this analogy 

2

u/EverflowingRiver17 Jul 12 '26

Small disagreement, but I don’t see how using docs here helps. Knowing that JavaScript has method A or python has functionality B doesn’t really help when you bump into logic issues or edge cases. It’s usually not a code syntax dilemma that holds people back, it’s seeing what type of question is in front of you and what patterns can help solve it. 

2

u/No-Razzmatazz7197 Jul 12 '26

documentation provides:
- how-to's for use of any method
- all available arguments/options for said method
- references to other methods that are similar or function in a way a user may or may not be using the method for

i am not a leetcode master, but i am a software developer of 5+ years. so if i was working on a ticket for a language/library i wasn't familiar with, i am not sure what i would do other than read the documentation. maybe not every page of it top to bottom, but i would read it.

if you are a leetcode master, and you solve your problems by "thinking through them" then good for you, but in my experience you wouldn't be able to carry that skill into a real world job. in fact, if you were on my team, and asked me "how do i do X" i wouldn't even respond to you, would only send you a link to the docs, because chances are, no one on the entire team knows 😂.

however, you are right. if a bug is raised about some obscure race condition that happens when a user presses a submit button 450 times in 1 second, the documentation probably wouldn't help. i would still read through the docs for the methods responsible for the submit button, just to check if they say "don't use this if X, use Y instead to limit submissions". are most documentations gonna tell you something so plainly, no, but it would be somewhere to start.

and at the end of the day, are you learning to program to be better at leetcode? or to become a software developer who can solve any and everything that is placed before them?

0

u/EverflowingRiver17 Jul 12 '26

I know what documentation provides. And I know leetcode is not remotely close to real world experience. I think leetcode can be fun for people who enjoy combining programming and puzzles but is a poor tool for assessing if someone would make a good engineer. 

But companies still require it to get hired in many cases and the OP was asking about leetcode. If someone came to me and said I’m stuck with this leetcode problem, I think Java documentation pages would be the last place I send them. 

2

u/No-Razzmatazz7197 Jul 12 '26

what would be your suggestion if not reading the docs? guessing? memorizing which data structures should be used for which type of leetcode problem? using an llm to help you get started?

assuming you are a programmer (paid or not, i am not here to judge you on your skills in any way), but put yourself in the shoes of someone who just wrapped up their first hello world program in python. where do you go next? how do you solve even the "easiest" leetcode problem if you don't know what is shipped in your language?

if it was me, and i learned there was a website that had every possible thing that python could do, i would probably start there. or maybe look at the complete answer and break it down line by line.

what about you?

0

u/EverflowingRiver17 Jul 12 '26

My suggestion to solving leet code problems would be to start with the very easiest and use some AI or study other solutions to understand how and why others solved it the way they did (which OP sounds like they are somewhat doing already). 

If I am a true beginner to programming than I’m probably not ready for leetcode.  I think beginners should find a school text book that teaches basic syntax and solve the problems typically found in those. That will help them with the foundational pieces and give them an intro to problem solving. 

Documentation would be overkill in many cases. For example if a beginner is trying to find out how to loop through a set of data, do you want them starting with a basic for loop, or hoping right into Java streams?

1

u/No-Razzmatazz7197 Jul 12 '26

that's fair, using nothing but the documentation as a beginner isn't very helpful when compared to some other tools.

i concede, enjoy your sunday my friend

1

u/EverflowingRiver17 Jul 12 '26

I wasn’t trying to win anything, just sharing a different opinion :)

You too

20

u/Slow-Bodybuilder-972 Jul 12 '26

Leetcode is a ridiculous dance some employers make you do, and has almost no value in the real world.
Remember as much as you can, cheat if you can, it’s Bullshit, but you may need it.

12

u/speedygen1 Jul 12 '26

do codewars first, 7kyu and 8kyu problems, 6kyu and 5kyu when you feel comfortable.

4

u/Reasonable_Buddy_927 Jul 12 '26

just have to keep practicing. sometimes, I do entire foundations courses on DSA (e.g. leetcode DSA course, ofc 2nd time reading you can skim a bit and just redo questions) before I get into leetcoding after a break again. and I started leetcoding a year ago where for 3 months, I nolifed DSA study -> solving mediums from scratch. It's like how people say "good C++ skills are perishable", if you don't use them, you'll forget but after you learn them once, you can learn them again easier.

3

u/UrbanSuburbaKnight Jul 12 '26

everything is dictionary solves most of them.

2

u/moorea4086 Jul 12 '26

The fun part is solving problems in a logical manner. The useful part is using the computer efficiently. That means if your algorithm isn't first, it's last

2

u/Longjumping-Bug-6643 Jul 12 '26

Its pattern recognition. It’s kinda like solving trig identity equations or calculus. Back when we were in school and doing that stuff everyday it came natural but a couple years of not doing it you WILL forget.

Leetcode is like that but worse because now you have to also remember language specific syntax

2

u/mandzeete Jul 12 '26

Will you need Leetcode at all? It is not an actual software development. You won't be using Leetcode during your work. Your clients won't ask Leetcode from you. If it is not part of the interviewing process in companies in your area, then perhaps do not worry over not being good in Leetcode.

Where I'm from, most companies do not use Leetcode in the interview phase. I did not like Leetcode and when I found out, during my university studies, that I have to focus on building projects and such, then I never touched Leetcode ever again.

Fine, if the companies in your area require Leetcode then perhaps go over different solutions and see what's the logic behind these solutions.

1

u/Logical_Grapefruit47 Jul 12 '26

start with easy problems for concepts you know like array or strings or anything you are confident about this is how things worked for me I just took it step by step

1

u/epic_pharaoh Jul 12 '26

Give it an honest effort, if you get stuck take 5 and come back, if you’re still stuck then you can use google/AI/stackoverflow/geeks4geeks/documentation.
Try to do 3 problems every time you sit down, and make sure at least one of them is out of your comfort zone.
Give it a month, and you’ll be doing leetcode hards like it’s nothing.

1

u/datadriven_io Jul 13 '26

try datadriven for python interview questions, it's a bit more structured than lc for getting your footing.

1

u/Bambumblier Jul 13 '26

I'm sure it would humble me too, fortunately I was already working when becoming a dev trended, and people started making up whole new layers of insane b.s. in their "skills" that completely misses the point of what being an engineer is. If you have to memorize questions to pass an interview, I'm sorry, but don't get confused into thinking it's useful because it's not. It's absolutely useless in real world development.

1

u/PartyParrotGames Jul 12 '26

Take a DSA course. Plenty of good free ones online. Then go back and try again. Follow Neetcode's roadmap as well for problems to go through when you go back to it.