retagged by
542 views
5 votes
5 votes

$$
\begin{aligned}
& S \rightarrow S1 \;T \\
& S 1 \rightarrow a \mid(S S) \\
& T \rightarrow \varepsilon \mid b \;T
\end{aligned}
$$
In the $\text{LL(1)}$ parser table, $M$, of the grammar the entries $M[S 1, a]$ and $M[T, a]$ respectively are -

  1. $\{S 1 \rightarrow a\}$ and $\{T \rightarrow b T\}$
  2. $\{S 1 \rightarrow(S S)\}$ and $\{T \rightarrow b T\}$
  3. $\{S 1 \rightarrow(S S)\}$ and $\{T \rightarrow \varepsilon\}$
  4. $\{S 1 \rightarrow a\}$ and $\{T \rightarrow \varepsilon\}$
retagged by

1 Answer

2 votes
2 votes

 

edited by
Answer:

Related questions

559
views
1 answers
2 votes
GO Classes asked Jan 21
559 views
Consider the following grammar:$\begin{aligned}& S \rightarrow a S^{\prime} \\& S^{\prime} \rightarrow b S^{\prime} \mid \epsilon\end{aligned}$Which of the following is/are ... $bS'$a S^{\prime} b$bbS$
694
views
1 answers
5 votes
GO Classes asked Jan 21
694 views
Consider the following grammar- ... .$\operatorname{First}(\mathrm{A})$ and $\operatorname{First}(\mathrm{T})$ are same.
455
views
1 answers
4 votes
GO Classes asked Jan 21
455 views
Consider the following context-free grammar, with start symbol $S$ and terminals $a, ; , \lt , \gt .$ ... many different parse trees are there for the string $\lt \lt a \gt ;a\gt ?$