E -> id | id ( E ) | E + idbuild an SLR parser by drawing the state machine and then constructing the parsing tables.
R -> a R | aand
L -> L a | aSuppose we construct an LR(1) parser for each and in each case parse an input consisting of n tokens, each of which is an
a. What is the maximum depth of the parser stack in each case? Justify your answer.