LEVEL 4 OF 5
Graph Algorithms
Explore connections and find your way.
3 problems
DFS
Explore one branch as far as possible before returning to other frontier entries.
Explore topic2 problemsBFS
Explore vertices in increasing number of edges from the start, using a queue to finish one distance layer before the next.
Explore topic1 problemTopological Sort
Resolve a directed dependency graph by repeatedly removing vertices with no remaining incoming edges.
Explore topic1 problemUnion Find
Represent disjoint components by rooted parent forests and merge components by linking their roots.
Explore topic1 problemDijkstra
Finalize the nearest unfinished vertex, then relax outgoing edges to improve tentative distances to other vertices.
Explore topic2 problemsShortest Path
Associate each vertex with the least cost of reaching it under the problem's allowed moves.
Explore topic