COMPUTER SCIENCE AND ENGINEERING
THEORY OF COMPUTATION
Question
[CLICK ON ANY CHOICE TO KNOW THE RIGHT ANSWER]
|
|
ii i iv iii
|
|
iii iv i ii
|
|
iii i iv ii
|
|
ii iv i iii
|
Detailed explanation-1: -Examples. : the language of all strings consisting of n occurrences of the symbol “a", then n “b"’s, then n “c"’s (abc, aabbcc, aaabbbccc, etc.).
Detailed explanation-2: -A context-sensitive grammar (CSG) is a formal grammar in which the left-hand sides and right-hand sides of any production rules may be surrounded by a context of terminal and nonterminal symbols.
Detailed explanation-3: -In context sensitive grammar, there is either left context or right context (A i.e. is left context and is right) with variables. But in context free grammar (CFG) there will be no context. We cannot replace B until we get B0. Therefore, CSG is harder to understand than the CFG.
Detailed explanation-4: -In unrestricted grammars, productions have form u → v where u and v are any strings of terminals and/or variables. In context-sensitive grammars, productions have form xAz → xyz where x, y and z are strings of terminals and/or variables, and A is a vari-able.