Exam-style question
Try this first
In an unweighted graph, breadth-first search finds a path from S to G using three edges. What does this indicate?.
- A.The path contains exactly three vertices
- B.The path is the shortest path from S to G
- C.The path was found by depth-first search
- D.There is no other path from S to G
Answer and explanation
Concise answer
The path is the shortest path from S to G
Why this is correct
Breadth-first search explores an unweighted graph by increasing distance from the starting vertex, so the first path it finds to G uses the fewest edges.
Use the concise answer above for a quick check, then reveal the full model answer and detailed explanation.
Common mistake
No common mistake is linked to this question yet.
