Consider the following grammar along with translation rules. \[ S \rightarrow S_1 \# T \,\,\,\,\,\,\{S_{\centerdot\text{val}} = S_{1\centerdot\text{val}}* T_{\centerdot\text{val}}\} \] \[ S \rightarrow T \,\,\,\,\,\,\{S_{\centerdot\text{val}} = T_{\centerdot\text{val}}\} \] \[ T \rightarrow T_1 \% R \,\,\,\,\,\, \{T_{\centerdot\text{val}} = T_{1\centerdot\text{val}} \div R_{\centerdot\text{val}}\} \] \[ T \rightarrow R \,\,\,\,\,\,\{T_{\centerdot\text{val}} = R_{\centerdot\text{val}}\} \] \[ R \rightarrow \text{id} \,\,\,\,\,\,\{R_{\centerdot\text{val}} = \text{id}_{\centerdot\text{val}}\} \] Here \(\#\) and % are operators and id is a token that represents an integer and \( \text{id}_{\text{val}} \) represents the corresponding integer value. The set of non-terminals is {S, T, R, P}, and a subscripted non-terminal indicates an instance of the non-terminal.
Using this translation scheme, the computed value of} \( S_{\text{val}} \) for root of the parse tree for the expression \(20\#10%5\#8%2\#2 \) is
Consider the following grammar (that admits a series of declarations, followed by expressions) and the associated syntax directed translation (SDT) actions, given as pseudo-code:
P → D* E*
D → int ID {record that ID.lexeme is of type int}
D → bool ID {record that ID.lexeme is of type bool}
E → E1 + E2 {check that E1.type = E2.type = int; set E.type := int}
E → !E1 {check that E1.type = bool; set E.type := bool}
E → ID {set E.type := int}
With respect to the above grammar, which one of the following choices is correct?

Consider the following code:
int a;
int arr[] = {30, 50, 10};
int *ptr = arr[10] + 1;
a = *ptr;
(*ptr)++;
ptr = ptr + 1;
printf("%d", a + arr[1] + *ptr);
In the diagram, the lines QR and ST are parallel to each other. The shortest distance between these two lines is half the shortest distance between the point P and the line QR. What is the ratio of the area of the triangle PST to the area of the trapezium SQRT?
Note: The figure shown is representative

Consider the following process information for Shortest Remaining Time First (SRTF) scheduling:
\[ \begin{array}{|c|c|c|} \hline \textbf{Process} & \textbf{Arrival Time (AT)} & \textbf{Burst Time (BT)} \\ \hline P1 & 0 & 10 \\ P2 & 1 & 13 \\ P3 & 2 & 6 \\ P4 & 8 & 9 \\ \hline \end{array} \]Find the turnaround time for each process.