Note: This is what I did. This is what I always tell my students. This is what I’m sharing because I believe it is very helpful for people here.
1. Are the tips I’m sharing the only way to reach Expert? No.
2. Is it the best way to reach Expert? Not necessarily, but I think so.
3. Can I leave hateful comments below? Do something more valuable lol. Write another blog explaining how you did it, or even a comment works.
4. Are you actually helping or just promoting your video? First, regardless of any benefit to me, this is valuable information for people. Second, I genuinely don’t need the promotion. 32,000 people have already watched it in a week, and this blog might add like 1,000 more, doesn’t make any noticeable difference for me.
Two types of advice
I believe advice generally falls into two types. Some advice is not controversial, so everyone agrees on it. By definition, it is ‘useless’ because it doesn’t add new knowledge. For example, telling someone to “practice” or “train hard” isn’t helpful since everyone already knows and agrees on that. It can serve as a reminder or motivation, but it doesn’t add knowledge.
On the other hand, some advice isn’t something you hear everywhere. Not everyone may agree with it. So, what I did here was share those kinds of opinions. And of course, anyone is free to agree or disagree in the comments. This is an open discussion.
Is there really a correct and incorrect way to learn competitive programming? Definitely. I’ve seen many people do it incorrectly. At the end of this blog, I’ll share experiences I’ve had with my previous students in different schools.
I’ll attach the video I've made at the end, but I’ll also summarize some of the key points for those who prefer reading.
Why am I so confident about this style? I've did it myself. As you can see in my rating graph, I went from newbie to expert in two months (March–May 2015), and after three months, I ranked 4th in a div 2 contest (still my best CP day ever). So, I confidently say that it works.
Okay, so what is it?
For example, I tell people to solve problems around their own rating. If your rating is 1200, solve many 1200-rated problems. It’s not a waste of time. Don’t jump to harder problems too soon. Many people do this, but they end up spending too much time thinking and not enough time implementing. Therefore, they become good at problem-solving but suck at implementation.
Also, don’t think too much. If you’re stuck, feel free to look at hints or solutions, that’s fine! You’re a beginner and you are building intuition. (Some people strongly disagree and think you should never check a solution, even if a gun is pointed at your head. I completely disagree, remember, you have just started.) I recommend choosing problem that on average you spend about 30 minutes per problem. (average! so you might solve some in 10 mins, and some in more than an hour) Some say, “Think on a hard problem for 5 hours and enjoy!” No. trust me, Accepting 10 different problems helps more at this stage. I also recommend reviewing other people’s code. Early on, this helps you write more efficient solutions.
And seriously, don’t start by learning algorithms. Just solve problems. Learning complex algorithms too early is mostly a waste of time. To reach expert, you only need to solve problems with tags like implementation, brute force, math, greedy, and DP. (DP is the only one that requires serious practice.)
Here you can see the full video:
This is a recurrent pattern, happened over and over again in my teaching experience. I start teaching in a school, and I see that after a year the students are still newbie/pupil at most. I work with them and in several months they get to expert. Why? The previous teacher was teaching them AVL tree (or similar things), solving very hard problems, etc. If you ask the students to explain some complex algorithm in a paragraph, they can do that. But if you give them a simple problem to accept, they can't.
Trust me, this is not the correct way to learn CP. And, yes, there is a correct way and an incorrect way.
Feel free to agree/disagree in the comments. It’s welcome and helps everyone to know opposite point of views.
I started CP after about a month, and now I suck more than I used to.
I used to be able to solve 1200 rated problems (except for ad hoc problems, they were too hard)
But now I cant even solve 1000 rated problems from TLE Eliminators CP sheet.
What should I do?
Edit: check my profile as well if anyone wants to help
Practice more(I guess).
This generally happens , when there in a gap of more than a week. This really sucks when we restart.
Agreed on your suggestion that solve problems around your own rating range ...like when I was 1500 rated I only solved 1500 rating problems and reached expert just after that
I think in the early stage solving problems faster(A, B, C in div 2) is more helpful than practicing div 2 D problems
I agree on this, you don't need to know a lot of algorithms to improve. However, I see quite few pupils/specialists who are learning Segment tree or any other complex data structure, and wondering why they aren't Experts yet. My theory is, people who just started Competitive programming believe, that learning some DSA of level X, helps them reach level X directly(no, it won't). But I don't know, maybe they have other reasons to study fancy DSA, let me know.
Anyways, if you want to reach Expert, for example, you don't have to be familiar with SegTree, BIT, Convex Hull(?) or any other complex data structure or algorithm. I think basic techniques like prefix sum, binary search, two-pointer, etc. are enough to be an Expert (maybe even CM).
i was a nearly stable CM without knowing any of the DSA above , they pretty much never appear in <= 2200
That's true. I learnt a lot of such stuff but rarely used in contests. Never solved 4 problems in a div 2 even though I can upsolve most Duv 2D under 1900 on my own, majorly because I need atleast 1.5 hours to do so and that kind of time isn't left when I reach it in a contest. However, from what I have noticed (while upsolving) that some high rated problems of those data structures are too easy for their ratings. For example an 1800 segment tree seems like a 1200 rated normal problem. Very little thinking and just a direct variation of something standard. Binary lifting seems to have a similar case (though not seen many cf problems of it). Same goes for trees/graphs. A 1600-1700 tree problem is just as hard as an 1100-1200 adhoc. Ironically I still can't implement it in a live contest but I think it's mostly because of the time left when I reach them and because they have comparatively longer implementation than a Div 2B (I mean easier to think of but harder to implement while the case is opposite with a B or C usually. Not talking of Ad-Hoc kind of Ds here but they are mostly not adv data structures if adhoc because from what i have seen adhoc trees, graphs etc are usually Div Es)
I've done the same so far, but I think I'm still far from expert and being consistent overall. (my performance just really depends on weather)