Java Operator Precedence
What is printed by the program and why?
public class ModuloPrecedence {
public static void main(String[] args) {
int result = 5 + 3 * 2 % 4;
System.out.println(result);
}
}
A
16
B
5
C
6
D
7
Question Leaderboard
Not enough data yet to show leaderboard.
APFIVE