Question

In Java, what will be the output of the following code snippet? public class Test {     public static void main(String[] args) {         int x = 5;         x = x++ + ++x;         System.out.println(x);     }}

A 10
B 12
C 11
D 13
E Compilation Error
Practice Next

Hey! Ask a query