The Breadth First Search (BFS) algorithm has been implemented using the queue…
GATE · 2017 · CS · Set 2 · Computer Science & IT
The Breadth First Search (BFS) algorithm has been implemented using the queue data structure. Which one of the following is a possible order of visiting the nodes in the graph below?

- A.
\(\text{MNOPQR}\) - B.
\(\text{NQMPOR}\) - C.
\(\text{QMNROP}\) - D.
\(\text{POQNMR}\)
Attempted by 603 students.
Show answer
Correct answer: D
The worked solution is available to enrolled students.
Video solution available to enrolled students.
Explore the full course: Iocl Engineers Officers Grade A Paper 2
Loading lesson…