开发者

What is hierarchy for these grammars: LL1,SLR1,LR0,LR1 and LALR1?

How are these grammars related to each other? e.g. SLR is a subset of LALR1. Is t开发者_运维问答here any set methods for working out the relationships between the others?


There are three types of Context Free Grammers(CFG'S).

1)Floyd-Evans Parsable 2)Unambiguous CFGs 3)Operator Precedence

All the ones u have mentioned above are Unambiguous CFG'S.

LL(0) < LL(1) < LL(k). LR(0) < SLR(1) < LALR(1) < LR(1) < LR(k). Also, LL(k) < LR(k)

Every LR(0) grammer id SLR(1) and every SLR(1) is LALR(1) which in turn is LR(1).

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜