Discussion on Graphs
Explore the fundamentals of graph structures and their implementations using adjacency lists. Understand the breadth-first-search and depth-first-search algorithms, including their time complexities and real-world applications such as maze exploration and planarity testing.
We'll cover the following...
We'll cover the following...
Additional notes
The running times of the depth-first-search and breadth-first-search algorithms are somewhat overstated by the following theorems we explained before:
- When given as input a
Graph,g, that is implemented using theAdjacencyListsdata structure, thebfs(g, r)algorithm runs in time. - When given as input a
Graph,g, that is implemented using theAdjacencyListsdata structure, thedfs(g,r)anddfs2(g,r)algorithms each run in