Syntax Analysis27

0. Consider the grammar
S → (S) | a
Let the number of states in SLR (1), LR (1) and LALR(l) parsers for the grammar be n1 n2 and n3 respectively. The following relationship holds good

  • Option : B
  • Explanation :
    Always the case SLR and LALR have same number of states.
    While LR have more states than these two.
    Because for any Bottom-up paring number of ‘CORES’ is always same while for LR() only other thing is lookahead is different.
Cancel reply

Your email address will not be published. Required fields are marked *


Cancel reply

Your email address will not be published. Required fields are marked *