Skip to content

UGC NET CS 2020Data Structures and Algorithms › Graph AlgorithmsVerified

UGC NET CS 2020 PYQ: Let $G$ be a simple undirected graph, $T_D$ be a DFS tree on $G$, and $T_B$ be the BFS tree on $G$. Consider…

Let $G$ be a simple undirected graph, $T_D$ be a DFS tree on $G$, and $T_B$ be the BFS tree on $G$. Consider the following statements.

Statement $I$: No edge of $G$ is a cross with respect to $T_D$

Statement $II$: For every edge $(u,v)$ of $G$, if $u$ is at depth $i$ and $v$ is at depth $j$ in $T_B$ then $\mid i-j \mid =1$

In the light of the above statements, choose the correct answer from the options given below

  1. A
    Both Statement $I$ and Statement $II$ are true
  2. B
    Both Statement $I$ and Statement $II$ are false
  3. C
    Statement $I$ is correct but Statement $II$ is false
    Correct answer
  4. D
    Statement $I$ is incorrect but Statement $II$ is true

Answer

(C) Statement $I$ is correct but Statement $II$ is false

Approach

Check the edge classification of DFS on undirected graphs and the depth property of BFS levels.

Reviewed by UGC IQ Editorial Team.