GATE CS 2024 Set 1 | Question 26

Compiler Design › Parser · MSQ · 1 mark · Answer: A, D

  1. Question 26Compiler Designmsq1 mark
    Which of the following is/are Bottom-Up Parser(s)?
    • A.
      Shift-reduce Parser
      ✓
    • B.
      Predictive Parser
    • C.
      LL(1) Parser
    • D.
      LR Parser
      ✓

    Answer: A, D

    Solution

    Answer: (A) and (D) Bottom-up parsers build the parse tree from leaves to root using shift-reduce actions: the generic Shift-reduce parser (A) and LR parsers (D). Predictive and LL(1) parsers are top-down.

More GATE PYQ on Parser

All GATE CS Compiler Design PYQ →

Attempt GATE CS 2024 Set 1 in real GATE exam mode

Full paper with a timer, the GATE interface and a topic-wise analysis — free.

Create free account →