BFS works 100%, DFS needs max frontier and max depth