Which of the following grammars are ambiguous?
GATE · 2026 · CS · Set 2 · Computer Science & IT
Which of the following grammars are ambiguous?
- A.
𝑆 → 𝑎𝑆𝑏 | epsilon
- B.
E→ 𝐸 + 𝐸 | 𝐸 ∗ 𝐸 | 𝑖𝑑
- C.
S→ 𝑎𝑆 | 𝑆𝑎 | epsilon
- D.
S → 𝑎𝑆 | epsilon
Attempted by 84 students.
Sign up free to check your answer
Sign up freeLoading lesson…