Directions: Please write your answers on this exam.
private void X() { // 1: start of code to parse the statement if (next == '{') { scan(); // 2: start of code to parse next portion E(); } else error(); // 3: start of code to parse next portion if (next == '?') { scan(); while (next != '}') { S(); // 4: location for code inside loop } else error(); if (next == '}') scan(); else error(); // 5: end of code for statement }
int F(int x, char y) { int a[4] = {1, 2, 3, 4}; return a[2]; }what additional information will be placed in the object?
% java ParenLisp 1 + 2 * 3 $ (+ 1 (* 2 3)) % java ParenLisp (1 + (2 * 3)) $ (+ 1 (* 2 3)) % java ParenLisp 1*(2+3)$ (* 1 (+ 2 3)) | % lisp > (+ 1 (* 2 3)) 7 > (* 1 (+ 2 3)) 5 > (quit) % |