Which variable does not drive a terminal string in grammar? S -> AB A -> a B…
2011
Which variable does not drive a terminal string in grammar? S -> AB A -> a B -> b B -> C
- A.
A
- B.
B
- C.
C
- D.
S
Attempted by 53 students.
Show answer & explanation
Correct answer: C
Variable C appears only on the right-hand side of B -> C and lacks any production rules. Unlike A, B, and S which derive terminals 'a' or 'b', C cannot generate a terminal string.