COMPUTER SCIENCE AND ENGINEERING
THEORY OF COMPUTATION
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
|
Every CFG for L is ambiguous
|
|
Every CFG for L is unambiguous
|
|
Every CFG is also regular
|
|
None of the mentioned
|
Detailed explanation-1: -Which of the following statements are correct for a concept called inherent ambiguity in CFL? Explanation: A CFL L is said to be inherently ambiguous if every CFG for L is ambiguous.
Detailed explanation-2: -A CFL L is inherently ambiguous if every CFG for L is ambiguous.
Detailed explanation-3: -If every Context-Free Grammar G with Language L = L(G) is ambiguous, then L is said to be inherently ambiguous Language. Ambiguity is a property of grammar not languages.
Detailed explanation-4: -Explanation: A context free grammar is ambiguous if it has more than one parse tree generated or more than one leftmost derivations. An unambiguous grammar is a context free grammar for which every valid string has a unique leftmost derivation.
Detailed explanation-5: -A language that only admits ambiguous grammars is called an inherently ambiguous language. Deterministic context-free grammars are always unambiguous, and are an important subclass of unambiguous grammars; there are non-deterministic unambiguous grammars, however.