term method
Implementation
double term() {
double x = factor();
while (true) {
if (match('*')) {
x *= factor();
} else if (match('/')) {
x /= factor();
} else {
break;
}
}
return x;
}
double term() {
double x = factor();
while (true) {
if (match('*')) {
x *= factor();
} else if (match('/')) {
x /= factor();
} else {
break;
}
}
return x;
}