A given grammar is called ambiguous if , ISRO 2020

2020

A given grammar is called ambiguous if , ISRO 2020

  1. A.

    two or more productions have the same non-terminal on the left hand side

  2. B.

    a derivation tree has more than one associated sentence

  3. C.

    there is a sentence with more than one derivation tree corresponding to it

  4. D.

    brackets are not present in the grammar

Attempted by 62 students.

Show answer & explanation

Correct answer: C

An ambiguous grammar is formally defined as a context-free grammar where at least one string in the language has more than one distinct parse tree or derivation tree.

This implies that there exists a sentence with more than one derivation tree corresponding to it, which is the core condition for ambiguity.

Explore the full course: Isro