search
Log In
1 vote
841 views

Let 'x', 'y', 'z' and 'u' represents the number of entries in rows of Non-terminals 'S', 'A', 'B' and 'C' respectively. The value of x + y + z + u is ______ .

in Compiler Design
edited by
841 views
0
simply asked number of entries for grammer in table which are left.
0
Ya but i found half of the answers wrong on madeeasy test series..
2
I think question itself is wrong.Given grammar is not LL(1).
1

Question not asking grammar is LL(1) or not . Since if table contain 2 entry for particular column then not LL(1) , Here simply ask number of entries.

3 Answers

0 votes
i think correct answer is 16 but they have given it 18. somebody please solve this problem
0 votes
how this grammer is LL(1)..

it is having left recursive production(B-->Bb)
0

I got 16 but in answer key its 18. I think I am correct.

 

0
Isn't first of ( B -> Bb/∊) Should be ∊ only?
0
No after getting € we substitute it in production to get b also as the first.

 

Eg :

A->Bb

B-->€

 

In this first of A={€, b}

Same concept can be applied to the left recursive grammar also.
0
Thank you for the explanation.
0
Welcome..
0 votes

I got 16 but in answer key its 18. I think I am correct.

 

Related questions

1 vote
0 answers
1
367 views
Why ε is not shown in First(S). First(s) does contain ε . And please help me figure out which grammar is this? According to me it is NOT LL(1) (since it is left factored), NOT LR(0) (Since the Item 0 has a R-R conflict), NOT SLR(1) (The item 0 has a RR conflict since Follow(X) = Follow(Y) = {a,b} correct me If i'm wrong
asked Nov 23, 2018 in Compiler Design Hopealways 367 views
1 vote
0 answers
2
2 votes
0 answers
3
665 views
Consider the following grammar which is not LL(1) because LL(1) table contain multiple entry for same production. The number of entries have multiple productions in LL(1) table are ________.
asked Aug 19, 2018 in Compiler Design Mizuki 665 views
0 votes
0 answers
4
92 views
Let G be a grammar with the following productions: If LR(1) parser is used to construct the DFA using the above productions, then how many look-a-heads are present for an item T → .T * F in the initial state ________.
asked Jun 12, 2018 in Compiler Design syncronizing 92 views
...