I've searched the standard but didn't notice the mentioned part.
Is it just "anything but 0" and 1 or it is compiler-dependent?
The result of the logical negation operator
!
is 0 if the value of its operand compares unequal to 0, 1 if the value of its operand compares equal to 0. The result has typeint
.
Appears in C89/C90, C99, and C11.