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 scosma = 8; double neprur = 2.0; int iclo = 7;
...draw the AST and evaluation results for the following expression:
scosma - neprur * 7 + iclo - 7 % 5 - 4 * 0 - 7
Things to double-check in your solution:
Given the following variables:
int e = 2; boolean erm = true; int dio = 9; double channac = 4.0; int si = 7; boolean woish = false;
...draw the AST and evaluation results for the following expression:
9 == e || erm == (!(dio != 6)) != (3 == 2) != 0 > channac == 3 < si || 4 <= 2 || woish
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 + 9
Things to double-check in your solution:
Related puzzles: