change a few little things in BFS
Edges are not string names anymore, they consist of two vertices