Working depth first search, beginning breadth first.