What is the output of the Java statement System.out.println(“5” + 3 + 2);?
Correct answer C. 532
Explanation
Evaluation is left to right. "5" + 3 makes the string "53", and adding 2 to a string concatenates again, giving "532".
Answer checked How we write and check questions
Discussion