When I run this Java code:
int[] a = new int[10];
int i = 0,j = 0;
while(i < 10){
a[i++] = j+++j++;
}
System.out.println(Arrays.toString(a));
I get as output: [1, 5, 9, 13, 17, 21, 25, 29, 33, 37].
Can someone please explain how the statement a[i++] = j+++j++ is resolved.