Fix loading a graph from the adjacency list (let the number of vertices be the largest index that appears in the list)