Professional Documents
Culture Documents
Advantages of BFS
A BFS will find the shortest path between the starting point and any other reachable node.
Used to find the shortest path between vertices
Always finds optimal solutions.
There is nothing like useless path in BFS, since it searches level by level.
Finds the closest goal in less time
Disadvantages of BFS
All of the connected vertices must be stored in memory. So consumes more memory