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. MNOPQR
B. NQMPOR
C. QMNROP
D. POQNMR
Answer:D
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. MNOPQR B. NQMPOR C. QMNROP D. POQNMR