added simple breadth first search