adding adjacency list data structure