7 votes 7 votes Which of the below relations does hold TRUE regarding GRAMMARS? $LL(1) \subset SLR(1) \subset LR(1)$ $SLR(1) \subset \epsilon-\text{free}\; LL(1) \subset LR(1)$ $\epsilon-\text{free}\;LL(1) \subset SLR(1) \subset LR(1)$ $LL(1) \subset SLR(1) = LR(1)$ Compiler Design go-cd-1 + – Arjun asked Jan 26, 2019 Arjun 1.1k views answer comment Share Follow See all 8 Comments See all 8 8 Comments reply venkatesh pagadala commented Jan 26, 2019 i reshown by venkatesh pagadala Feb 8 reply Follow Share Why 'A' is wrong??? @Arjun 0 votes 0 votes akash.dinkar12 commented Jan 26, 2019 reply Follow Share There are some grammar exists which are not SLR but they are LL(1) that's why A is wrong 2 votes 2 votes venkatesh pagadala commented Jan 26, 2019 reply Follow Share Can you explain why C is correct?? 0 votes 0 votes sripo commented Jan 27, 2019 reply Follow Share How is B True? 0 votes 0 votes Arjun commented Jan 27, 2019 reply Follow Share Every $\epsilon$-free LL(1) is SLR(1) - you can see this in any Compiler text or even Wikipedia. @sripo B is not true 3 votes 3 votes !KARAN commented Jan 28, 2019 reply Follow Share If $\epsilon - \text{free LL(1)} = SLR(1)$ then how option C is correct? 1 votes 1 votes ankitgupta.1729 commented Jan 29, 2019 reply Follow Share every $\epsilon$-free LL(1) grammar is SLR(1) grammar means the set of $\epsilon$-free LL(1) grammars is within the set of SLR(1) grammars. To prove 2 sets A and B are equal , we have to prove that $A\subseteq B$ and $B\subseteq A$. So, if we consider $\epsilon$-free LL(1) = SLR(1) is true then all the SLR(1) grammars should also be the subset of set of $\epsilon$-free LL(1) grammars which is not true. 4 votes 4 votes amit166 commented Jan 29, 2019 reply Follow Share if in case $\epsilon $ free grammar is not LL(1) A->Ax/y grammar but not LL(1) Also $\epsilon $ free ithink first option right it it hold any type of CFG 0 votes 0 votes Please log in or register to add a comment.
2 votes 2 votes Answer : C ϵ−free LL(1) ⊂ SLR(1) ⊂ LR(1) because every ϵ−free LL(1) are SLR(1) and every SLR(1) are LR(1) shivam001 answered Nov 16, 2019 shivam001 comment Share Follow See all 0 reply Please log in or register to add a comment.