Consider an ambiguous grammar G and its disambiguated version D. Let the…

2007

Consider an ambiguous grammar G and its disambiguated version D. Let the language recognized by the two grammars be denoted by L(G) and L(D) respectively. Which one of the following is true ?

  1. A.

    L (D) ⊂ L (G)

  2. B.

    L (D) ⊃ L (G)

  3. C.

    L (D) = L (G)

  4. D.

    L (D) is empty

Attempted by 25 students.

Show answer & explanation

Correct answer: C

Disambiguating a grammar means resolving ambiguities in its production rules without changing the language it generates. The disambiguated version D is constructed to produce the same set of strings as the original grammar G, but with unambiguous parse trees. Therefore, L(D) must equal L(G). The correct option is C, which states L(D) = L(G), matching the fundamental property of grammar disambiguation.

Explore the full course: Gate Guidance By Sanchit Sir