Choose the correct statement

Choose the correct statement

  1. A.

    None of these

  2. B.

    1-2, 1-5 are tree edges

  3. C.

    6-7, 1-8 are forward edges

  4. D.

    6-3, 2-4 are back edges

Attempted by 90 students.

Show answer & explanation

Correct answer: B

This will explain the diagram:-

Forward edge: (u, v), where v is a descendant of u, but not a tree edge.It is a non-tree edge that connects a vertex to a descendent in a DFS-tree.

Cross edge: any other edge. Can go between vertices in same depth-first tree or in different depth-first trees. (layman)

It is any other edge in graph G. It connects vertices in two different DFS-tree or two vertices in the same DFS-tree neither of which is the ancestor of the other.(formal)

Explore the full course: Dsssb Tgt Computer Science Paper 2