The following program prints 0, i thought it will print 1.
class
Test {
public static void main(
String []args) {
int x=0;
x=x++;
System.out.println(x);
}
}
But the following program prints as expected...
class Test {
public static void main(String []args) {
int x=0;
x++;
System.out.println(x);
}
}
Could some body explain in detail what is happening in detail.
Advance Thanks...