Skip to content
Official PYQ · 2014

GATE CS 2014 Set 1 Q38 — Turing Machines

Explain with AI

Suppose a polynomial time algorithm is discovered that correctly computes the largest clique in a given graph. In this scenario, which one of the following represents the correct Venn diagram of the complexity classes P, NP and NP Complete (NPC)?

Choose one option
View worked solution

Answer: D

The CLIQUE problem (finding whether a graph contains a clique of size kk) is a well-known NP-complete problem. Finding the size of the largest clique is the optimization version of this problem.

If a polynomial-time algorithm is discovered to compute the largest clique, then the NP-complete decision version of CLIQUE can also be solved in polynomial time. This implies:

P=NP\text{P} = \text{NP}

When P=NP\text{P} = \text{NP}, every NP-complete problem can be solved in polynomial time, meaning NPC⊆P\text{NPC} \subseteq \text{P}. Since NPC\text{NPC} is already a subset of NP\text{NP} by definition, all three classes collapse into the same set (excluding the trivial languages ∅\emptyset and Σ∗\Sigma^*):

P=NP=NPC\text{P} = \text{NP} = \text{NPC}

Thus, the correct Venn diagram must represent all three classes as identical, which corresponds to Option D.

Free practice · Your answers on this page are not saved.

Published
Report a correction
Keep exploringMore Turing Machines questions