Overview
An edge list stores each edge as a pair or record of endpoints. It is simple, compact for algorithms that scan edges, and common in graph input formats.
Represents a graph as a list of edges, optionally with weights or other edge data.
Compact metadata for implementation and discovery.
An edge list stores each edge as a pair or record of endpoints. It is simple, compact for algorithms that scan edges, and common in graph input formats.
Quick facts
Runtime and memory behavior at a glance.
Best
O(1)
Average
O(E)
Worst
O(E)
Space
O(E)
Show storing graph edges as endpoint records on a small graph representation example.
Edge lists are easy to store and sort, but they are not optimized for neighbor queries.
What each reference supports for this entry.
Reference for Edge List Representation graph representation choices and traversal implications.
Good next jumps from the relationship graph, ranked for useful discovery.
Data Structures · Foundation
Adjacency lists organize the same graph around neighbor queries instead of edge scans.
Compare with thisAdjacency lists organize the same graph around neighbor queries instead of edge scans.
Adjacency matrices favor direct edge-existence checks at higher memory cost.
CSR stores sparse adjacency more compactly for indexed traversal and numerical-style graph processing.