794 views
0 votes
0 votes
Please provide example to disapprove the following points:-

1.every DCFG need not be a  LR(K).

2.every DCFG need not be a LL(K).

3.every DCFL is not LL(k).

2 Answers

1 votes
1 votes
  • If a GRAMMAR  is ambiguous  then it never be LL(1),LR(K) ,

Example:   S-->SS/a

1 votes
1 votes

first thing we should note that LL(k) and LR(k)   both accept unabiguous grammar

now come to question 

a)  we know that DCFG can be ambiguous so DCFG can be LR(k)  or can  not be LR(k) so this option is true

b)  we know that DCFG can be ambiguous so this option is true 

c)  grammar which generate DCFL may be ambiguous  or unambiguous so this option is false  because they are saying every DCFL is not LL(k)

Related questions

13 votes
13 votes
2 answers
1
Prajwal Bhat asked Jan 15, 2017
5,300 views
1. LL(k) grammars have one to one correspondance with DCFL's2. LR(k) grammars have one to one correspondance with CFL'sWhich of them is True and explain it bit clearly?
0 votes
0 votes
1 answer
2
Sahil1994 asked Nov 30, 2017
315 views
HI Mates, Is it true or false..? If yes or no please explain..?Every Regular set has a LR(1) Grammar....?
0 votes
0 votes
1 answer
4
Ayush Upadhyaya asked Mar 20, 2017
560 views
For the language L = { anbmcmdn : n , m>=1 }I came with following set of productions :S >aSd | AA bAc | bcwhereas the answer was given as belowS aSd | aAdA bAc | bcho...