Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
if-statement with two checks with different data types
#6
The relevant section in C99 is 6.5.8(6):

Quote:Each of the operators(greater than), = (greater than or equal to) shall yield 1 if the specified relation is true and 0 if it is false. The result has type int.

The usual arithmetic conversions take place on the operands before the the comparison takes place.
<t></t>
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)