trival list iteration improvement and name change
undirected edge supported
BFS