For each of the Java expressions below:
Be sure that your tree accurately reflects how Java would evaluate the expression.
Given the following variables:
double cel = 4.0; int phra = 8; int caphpre = 1; double spetre = 5.0;
...draw the AST and evaluation results for the following expression:
5 / cel % phra % caphpre % 3 / 7 * 8 - spetre
Things to double-check in your solution:
Given the following variables:
double thrusm = 3.0; boolean ceur = true; boolean fi = true; double rard = 4.0; double se = 3.0; boolean icosm = true;
...draw the AST and evaluation results for the following expression:
thrusm < 6 != ceur && fi == (rard == se) == !icosm && 5 > 9 && !(0 > 4)
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: