Which of the following is true?
2014
Which of the following is true?
- A.
Canonical LR parser is LR(1) parser with single look ahead terminal
- B.
All LR(k) parsers with k > 1 can be transformed into LR(1) parsers
- C.
Both (A) and (B)
- D.
None of the above
Attempted by 16 students.
Show answer & explanation
Correct answer: C
Option A correctly defines Canonical LR parsers as LR(1) with a single lookahead symbol. Option B is valid because all LR(k) grammars for k>1 can be transformed into equivalent LR(1) parsers. Since both statements are theoretically accurate, Option C is the correct choice.
A video solution is available for this question — log in and enroll to watch it.
Loading lesson…