What algorithms need to learn to get 5 star?

i’am new to competitive programming and my knowledge is not sufficient to earn more stars .
So please say what algorithm need to learn or to be good …


Dude from your post header, you seem to be greedy to get there over night. It will take time, TBH.
I don’t want to overwhelm you.
Go up and solve easy problems (Beginners section) for 10 days. Solve like 50 - 80 problems and come back and read further.

Now If you want to read down further, you will feel heavy.So, go back and start solving easy ones. Gud luck. Aim 2 stars first! :slight_smile:

(Not specifically )BitMasking, DP, Greedy and

try to see all those problems which has 10^5 length (strings) and can be solved in linear time (Most probably, problem 3 of cookoff/lunchtime some 3 outta 10 times).

Including above, you need to know a lot of things to be consistent as 5 star. Eg., manacher, KMP, shortest paths, problems on trees, graphs, dfs, bfs. segment trees, decomposition techniques, kadanes etc…,

Solve 1,2,3,4 of divB on all cookoff,lunchtime starting 2017. You will c improvement.


Understanding of algorithms and consistency will help you in being 5 star.
Give each and every contest for let’s say 3 months. Try to upsolve as much as you can. You can learn algorithms as well during/after contest by searching it what you wanna do on Google appropriately as and when required.
I knew nothing about competitive and it took me 11 contests ( 4 months) to become 5 star. I want you to be 5 star in less duration.
It’s not like you learn algorithms and then you do competitive.
They will run parallely. You will learn them while doing competitive.


i will try my best…
Thanks Bro :grin:


Thanks it will help me a lot

1 Like

Thank you I was stuck on the same question.

1 Like

Thx bro