started work in breadth-first search. not working.