previous
|
index
BFS/DFS Efficiency Comparison Summary
BFS
DFS
Time
O(V+E)
O(V+E)
Space
O(a
d
)
O(a × d)
The difference between BFS and DFS can be seen clearly by applying them to a maze solving problem.
previous
|
index