StreakPeaked· Practice

ExamsGATETechnical

Let G = (V,E) be a directed graph where V is the set of vertices and E the set of edges. Then which one of the following graphs has the same strongly connected components as G ?

  1. G1 = (V,E1) where E1 = {(u,v) | (u,v) ∉ E}
  2. G2 = (V,E2) where E2 = {(u,v) | (v,u) ∈ E}
  3. G3 = (V,E3) where E3 = {(u,v) | there is a path of length ≤ 2 from u to v in E}
  4. G4 = (V4,E) where V4 is the set of vertices in G which are not isolated

Correct answer: G2 = (V,E2) where E2 = {(u,v) | (v,u) ∈ E}

Solution

G2 represents the transpose of the original graph G, where the direction of all edges is reversed. This operation preserves the strongly connected components, as the reachability between vertices remains intact in both directions.

Related GATE Technical questions

⚔️ Practice GATE Technical free + battle 1v1 →