What happens (behind the curtains) when this is executed?
int x = 7; x = x++;
That is, when a variable is post incremented and assigned to
It has undefined behaviour in C and for Java see this answer. It depends on compiler what happens.