int x = 0;
int y = 0;
(1 ? x : y) = 4;
A:
This is not legal in ANSI C:
6.5.15/4
If an attempt is made to modify the result of a conditional operator
or to access it after the next sequence point, the behavior is undefined.
However, in C++ we have:
5.16/4
If the second and third operands are lvalues and have the same type,5.16/5
the result is of that type and is an lvalue.
Otherwise, the result is an rvalue.
via linkedin.com, cpptrivia.blogspot.com