Skip to content
dsa/roadmap
← All chapters
Chapter 07Weeks 11–12Phase 3 ~2.8 h

Graphs

Vocabulary, adjacency matrix and list, directed graphs, BFS and DFS.

  1. 7.1Graph TerminologyVertices and edges, adjacency, degree, paths, cycles, connected graphs, weighted graphs, and how a tree is a special graph. 35 mineasy
  2. 7.2Adjacency Matrix & Adjacency ListTwo ways to store a graph in memory, what each costs, and when to choose which. 45 minmedium
  3. 7.3Directed GraphsOne-way edges, in-degree and out-degree, directed paths and cycles, and how the matrix and list change. 30 mineasy
  4. 7.4BFS & DFSBreadth-first search with a queue, depth-first search with recursion or a stack, the visited array, and O(V + E). 60 minmedium

Keyboard shortcuts

⌘K /
Search topics, glossary, cheat sheets
space
Play / pause the visualizer
← →
Step back / forward
r
Reset the visualizer
?
Show this help