Question: why bfs is better than dfs?
Answer: DFS uses Stack to find the shortest path. BFS is better when target is closer to Source. DFS is better when target is far from source. As BFS considers all neighbour so it is not suitable for decision tree used in puzzle games.