bfs and ucs ready