edited by
949 views
3 votes
3 votes

Consider the following grammar G:

                                                       

The number of states in SLR parser for G is _______.

My question is since this grammar can't generate any string the number of states should be zero right as we will remove useless symbols before constructing canonical collection of LR(0) items

edited by

2 Answers

1 votes
1 votes

7 states in SLR

0 votes
0 votes
7 states..the grammer is LR(0)..that is another thing it cant accept any srting

Related questions

0 votes
0 votes
1 answer
2
Na462 asked Jan 16, 2019
763 views
Which of the Statements are True :S1: LR(1) grammar can be LR(0) but not LL(1).S2 : Every regular language is LL(1)S3 : Three address code is linear representation of Syn...
3 votes
3 votes
1 answer
3
1 votes
1 votes
0 answers
4
rahul sharma 5 asked Oct 29, 2017
542 views
The given answer is 5,i am getting 616 in CLR and 10 in LALR.Please someone confirm?