Programming, Data Structures, Algorithms, Computer Science, Tech.
would look like in adjacency list format. Weighted graph as an adjacency list. Right off the bat, we’ll notice two things about this graph representation: first, since it is an undirected graph, the edge between nodes a and b will appear twice — once in the edge list for node a and once in the edge