Do C conditional statements always return [1 or 0], or do they return [0 or \'something other than zero\']. I ask because:
pseudo code -
f
Yes. This is guaranteed in C99. I don't have the C89 spec handy. Of course, compiler implementers have been known to make mistakes on occasion so YMMV.
C99 specifies the following in paragraph 6 of 6.5.8 Relational operators:
Each of the operators < (less than), > (greater than), <= (less than or equal to), and >= (greater than or equal to) shall yield 1 if the specified relation is true and 0 if it is false.
The same or similar clauses appear in paragraph 3 of 6.5.9 Equality operators, paragraph 3 of 6.5.13 Logical AND operator, and paragraph 3 of 6.5.14 Logical OR operator.