a[i] = i++;
The question is whether the subscript is the old value of i or the new. Compilers can interpret
this in different ways, and generate different answers depending on their interpretation. The
standard intentionally leaves most such matters unspecified. When side effects (assignment to
variables) take place within an expression is left to the discretion of the compiler, since the best
order depends strongly on machine architecture.
C programing 明确说了。。。在这种情况下使用哪个值根本不是C语言定的。。。全看编译器想怎么解释……
所以永远不要在一个表达式内多次使用被该表达式改变的变量。。。