Question 3 - BFS

Consider the following statements:

A. Given a tree T, it is possible to find the diameter of T using two BFS executions.

B. If an undirected graph is bipartite, it can be detected using BFS.

C. BFS was run on a connected simple graph, starting from a node r. Let u and v be two nodes in the graph. If the distance from r to u is 2, and the distance from r to v is 1, then the distance between u and v in the graph must necessarily be 1.

Which of the statements are correct?

a) Only A

b) Only B

c) A and B

d) B and C

e) None of the above


Comentarios

  1. Nice question. I took it. Remember to add "Original idea by: " and your name in the end.

    ResponderEliminar

Publicar un comentario

Entradas populares de este blog

Question 1 - DFS

Question 2 - Graph Theory