I'm reading Sams Teach Yourself Java and on the page about incrementing and decrementing the author says
int x = 7;
x = x++;
"In this example, the statement x = x++
increments the x variable from 7 to 8."
However the output is not 8, but 7 when complied. (no surprise there)
But then why does x++;
by itself give the output 8?