OK guys, I got this code-lines:
According to my understanding, ++ has a higher precedence than *, thus it will first increment x 4 times and later do the multiplying.PHP Code:
int x = 1;
int z = ++x * ++x * ++x * ++x;
However, what happens is that it increments the two first x's, later multiplies them, then it goes to the next x, increments it, and multiplies it with the result before and so on.
Am I missing something?
Trying to find something about it at the K&R book, but have no idea.
Thanks.