I need some recommendation on what order graph concept i should study

I recently had just completed studying Tree, and i Now thinking to start Graph or DP. But then seeing some trends on CP i thought to start Graph first and then learn DP, as it covers more Problems. But there is lot of material out there, it’s a really vast topic. So it would be better for me, if some of you from your experience can tell me, what are important topics to cover. And also tell me if it would be better to start Graph or should i learn DP, or maybe something else.
@galencolin @vivek_1998299 @l_returns @aryanc403


Learn both, then more :stuck_out_tongue:

1 Like

Definetly i have to learn both :joy:
But It’s the order i am asking for as it would be difficult or maybe confusing learning both the simultaneously, maybe learning something first benefits more as each individual topic is long so it might take weeks.

What I kind of (unclearly) mean is that the order doesn’t matter, as you’ll ultimately end up learning them both, right? The only immediate benefit is rating, but once you’re good enough your rating will rise to as high as it should be.


The order doesn’t matter given you eventually learn both.

Dynamic Programming is more of a concept than a set of algorithms. I think you should try to understand the concept of Dynamic Programming and use it in two or three cases. Then start learning graph topics. This will give you a framework to look at some graph algorithms (like Dijkstra’s, Floyd-Warschall) which are essentially DP on graphs. But despite of focusing on Graphs, still attempt the DP tasks in competitions. It is important to get a lot of practice with DP to master it.