A. Prerequisites

Competitive ProgrammingWeek 05

We have tried to keep the presentation self-contained. With this week we start our graph algorithms journey, and we will continue to focus on graph algorithms until Week 9. It would be a good idea to be comfortable with the fundamentals of graph representations (e.g, adjacency matrix v/s adjacency lists).

To recap BFS/DFS traversals, you can try out this module on Visualgo and watch the videos below:

and/or the following videos:

Learn more about graph representations and traversals in this book chapter.