How to determine whether a language is LL(1) LR(0) SLR(1)

前端 未结 7 1519
暗喜
暗喜 2020-12-08 07:56

Is there a simple way to determine whether a grammar is LL(1), LR(0), SLR(1)... just from looking on the grammar without doing any complex analysis?

For instance: To

7条回答
  •  执笔经年
    2020-12-08 08:51

    Check whether the grammar is ambiguous or not. If it is, then the grammar is not LL(1) because no ambiguous grammar is LL(1).

提交回复
热议问题