Question 9602 – Compiler-Design
February 13, 2024Question 9635 – Compiler-Design
February 13, 2024Question 9634 – Compiler-Design
Consider the grammar shown below
S → i E t S S' | a S' → e S | ε E → b
In the predictive parse table. M, of this grammar, the entries M[S’, e] and M[S’, $] respectively are
Correct Answer: D
Question 43 Explanation:
First(S) = {1,a}
First(S’) = {e,ε}
First(E) = {b}
Follow(S’) = {e,$}
Only when ‘First’ contains ε, we need to consider FOLLOW for getting the parse table entry.
![](https://solutionsadda.in/wp-content/uploads/2020/01/d44-2.jpg)
Hence, option (D) is correct.
First(S’) = {e,ε}
First(E) = {b}
Follow(S’) = {e,$}
Only when ‘First’ contains ε, we need to consider FOLLOW for getting the parse table entry.
![](https://solutionsadda.in/wp-content/uploads/2020/01/d44-2.jpg)
Hence, option (D) is correct.
{S’→e S} and {S’→ε}
{S’→e S} and { }
{S’→ε} and {S’→ε}
{S’→e S, S’→ε} and {S’→ε}
Subscribe
Login
0 Comments