Search code examples
c++operator-precedence

Is the order of evaluation defined for a[i++] = i;?


as title, in C++, is the evaluation order defined for

a[i++] = i;

?


Solution

  • No. You cannot use a single variable more than once in a full expression if at any point it's changed.