Machine-translated by Google. Questions are authored in English.
Top

Discussion

Which of the following is/are correct statement(s) :

(i) A language L is said to be a deterministic context free language if and only if there exists a deterministic ρDA M such that : L = L(M)
(ii) If every grammar that generates L is ambiguous, then the language is called inherently ambiguous.
(iii) A CFG is in Greibach Normal Form if all productions in G have the form A → BC and A → a where A, B, C are non-terminals and a is a terminal.

  • A.(i) and (iii) only
  • B.(ii) and (iii) only
  • C.(i) and (ii) only
  • D.(i), (ii) and (iii) only

Answer: C

The correct statements are (i) and (ii) only.

Statement (i), read with the printed 'ρDA' as PDA (pushdown automaton), is the definition of a deterministic context-free language: one accepted by some deterministic PDA. Statement (ii) is the definition of an inherently ambiguous language: every grammar generating it is ambiguous.

Statement (iii) is wrong: productions of the form A → BC and A → a define Chomsky Normal Form. In Greibach Normal Form every production has the form A → aα, a terminal followed by a string of non-terminals.

No comment is present. Be the first to comment.
Loading…

Post your comment

Please log in or register to post a comment.