Which of the following is the most powerful parsing method?

2012

Which of the following is the most powerful parsing method?

  1. A.

    LL(1)

  2. B.

    Canonical LR

  3. C.

    SLR

  4. D.

    LALR

Attempted by 121 students.

Show answer & explanation

Correct answer: B

Canonical LR (LR(1)) parsers are theoretically the most powerful among standard parsing methods. They can recognize a larger set of deterministic context-free languages compared to SLR, LALR, and LL(1) parsers.

A video solution is available for this question — log in and enroll to watch it.

Explore the full course: Mppsc Assistant Professor