Can anyone explain why output of following program excerpt gives value '6' for x ?
int x=8;
x-=--x-x--;//how this statement will be processed
printf("%d",x);
Printable View
Can anyone explain why output of following program excerpt gives value '6' for x ?
int x=8;
x-=--x-x--;//how this statement will be processed
printf("%d",x);
Because the behaviour is undefined as x is modified more than once between consecutive sequence points.