title: how signed and unsigned integers are stored in c?
body: <p>I am trying to run the following code but confused with what's happening here:</p>
  
  <pre><code>int main()
  {
   /* 
      a = -1; 
      b = 0xffffffff; 
   */
  if(-1 == 0xffffffff )
          printf("-1 is equal to maximum\n");
  else
          printf(" -1 is not equal to maximum\n");
  
  if(0xff &lt; -1)
          printf(" Less than -1 \n");
  if(0xff &lt; 0xffffffff)
          printf(" Less than maximum\n");
  </code></pre>
  
  <p>I tried with commented section as well and replaced -1 with "a" and 0xffffffff with "b" but the result is same .</p>
  
  <p>It's 32 bit system so i have taken integer size 4 bytes.</p>
  
  <p>My Output is :</p>
  
  <pre><code>-1 is equal to maximum
   Less than maximum
  </code></pre>
  
  <p>If -1 is equal to maximum then it should execute both of the last two if statements. But it's not happening. Why?</p>