Graph Theory37 sections · 1633 units
Open in Course

Quiz: Adjacency Matrix vs List

Knowledge check

Check Your Understanding

You have a graph with 10,00010{,}000 vertices and 15,00015{,}000 edges. Which representation uses less memory, and why?

  1. A.Adjacency matrix, because it avoids pointer overhead
  2. B.Adjacency matrix, because it stores each edge once
  3. C.Adjacency list, because it only stores 10,00010{,}000 entries
  4. D.Adjacency list, because it stores O(V+E)O(V + E) instead of O(V2)O(V^2)
Start the roadmap to answer the quizzes and solve the challenges