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 snon = 3; double niobo = 1.0; double qepa = 4.0;
...draw the AST and evaluation results for the following expression:
2 * snon - 7 / 7 / 1 + niobo - 7 / qepa
Things to double-check in your solution:
Given the following variables:
boolean fe = false; boolean ia = true; boolean enval = true; boolean primcad = false; double arl = 1.0; int nieflioss = 5;
...draw the AST and evaluation results for the following expression:
fe != ia == enval && primcad || 9 > 2 || 8 > 3 != arl < nieflioss
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: