For each of the Java expressions below:
Be sure that your tree accurately reflects how Java would evaluate the expression.
Given the following variables:
int chiied = 7; int co = 8; double gedca = 2.0; double ainalm = 2.0; int pe = 4;
...draw the AST and evaluation results for the following expression:
chiied + co / gedca / 5 + ainalm + 9 + 2 % pe
Things to double-check in your solution:
Given the following variables:
double masqe = 5.0; boolean qoss = false; boolean treng = true; boolean ste = true; int etris = 2; boolean wapre = false; double birmang = 3.0;
...draw the AST and evaluation results for the following expression:
(masqe >= 4 != !qoss && treng && ste) && etris >= 1 == wapre == birmang >= 9
Things to double-check in your solution:
Draw the AST and evaluation results for the following expression:
0 + 1 + 2 + "3" + 4 + 5 + 6 + "7" + 8
Things to double-check in your solution:
Related puzzles: