What is the highest type number that can be assigned to the following grammar?…
2016
What is the highest type number that can be assigned to the following grammar?
S → Aa
A → Ba
B → abc- A.
Type 0
- B.
Type 1
- C.
Type 2
- D.
Type 3
Attempted by 66 students.
Show answer & explanation
Correct answer: D
This grammar is classified as Type 3 (Regular). The productions S → Aa and A → Ba are left-linear, meaning non-terminals appear on the left side of terminals. Although B → abc has multiple terminals, finite regular languages often permit terminal strings in base cases under standard educational conventions. Since the grammar generates a finite language using left-linear rules, it fits Type 3.