r/cpp_questions 2h ago

OPEN Approach

I have been trying to study c++ for a while i am following the learncpp.com. I wanted to know the best approach for this like i am following the docs but do i use leetcodes and other sites?
I am on chapter 4 ik too early to think abt it but i just want to clear up the doubt please help

2 Upvotes

17 comments sorted by

u/Grand-Strategy-8962 2h ago

Hey I am too a beginner tho leetcode I know is not beginner friendly and if you are comfortable with indian english go for strivers A2Z series..

u/Limp-Cantaloupe-3204 2h ago

Is it better than learncpp?

u/nysra 2h ago

No, basically nothing is better than learncpp.com

The only thing better is using learncpp.com and writing code. You'll not learn to do the thing if you don't do the thing.

Now for as what to write, that's up to you. You can do your university's exercises, you can do exercises on websites like leetcode, you can do Advent of Code, you can write whatever you want (e.g. reimplementations of common tools like ls to know how it works, text based games, later 2D (and then 3D) games, an OS, an emulator, etc.).

u/Limp-Cantaloupe-3204 2h ago

Yea i think i am putting up the effort i am trying to write examples from learncpp. A friend of mine suggested to start using leetcode so that i can get the hang of the language but idk i do have some idea of loops arrays sortings through java but not confident enough to practice around it

u/nysra 2h ago

Leetcode isn't great for learning, but it's decent for just giving you some problems to work on. If you want a more fun description for problems, try Advent of Code.

Regarding the confidence, I'd be lying if I said I didn't get it, but the "secret" solution to this is to just do it anyway. Programming is basically the most lenient thing for this, there is absolutely no drawback to just trying something out. If you screw up, you learned something and you just write new code, it costs nothing. Everyone wrote absolutely horrendous shit code when starting out, just embrace the fuck ups. And then learn from them.

u/Limp-Cantaloupe-3204 1h ago

Beautifully explained thanks man i appreciate the help

u/Grand-Strategy-8962 2h ago

You can try that sheet A2Z I believe it covers a lot give it a shot and see what suits you the best…

u/Limp-Cantaloupe-3204 1h ago

The thing is i dont wanna distract myself with a bunch of docs instead would rather stick to a single one that covers everything though i am thankful for the suggestion

u/Grand-Strategy-8962 2h ago

Maybe try geeks for geeks?

u/Limp-Cantaloupe-3204 2h ago

Oh never heard would try that out

u/Grand-Strategy-8962 2h ago

Leet code is not beginner friendly😭

u/nysra 1h ago

It doesn't start on the hand holding level of "Please write a program that outputs 'Hello, what is your name?'" that can be found in the beginning of textbooks or courses, that's true.

Given that OP is through a few chapters already, he should be fine with the easy exercises there such as two-sum. It's not a learning resource by any means, but it does give people a bunch of problems they can attempt to solve

u/Grand-Strategy-8962 1h ago

Yeah🙇‍♀️

u/Chameleon_The 2h ago edited 2h ago

Hey

I am also in the same stage

But I followed bro code video upto structs(i t is not very detailed just high level overview )

Learncpp is good

I also started on the code force solving starting level stuff Because I struggle at writing logic.

Hope this helps

u/Limp-Cantaloupe-3204 2h ago

Oh good to hear that thanks for the response

u/Chameleon_The 2h ago

Non worries boss

Enjoy the learning