Got BFS working