title: Why does UINT_MAX return -1?
body: <p>I've written the following program which seems to work well for what I need to do. However, I wonder why UINT_MAX is giving me -1 in the output (via printf()) and not 4294967295, as specified here: <a href="https://www.tutorialspoint.com/c_standard_library/limits_h.htm" rel="nofollow noreferrer">https://www.tutorialspoint.com/c_standard_library/limits_h.htm</a></p>
  
  <pre><code>#include &lt;stdio.h&gt;
  #include &lt;limits.h&gt;
  
  int main () {
  
  printf("Below is the storage size for various data types.\n\n");
  
  //char data type
  printf("**char**\nStorage size: %d byte \t Minimum value: %d \t Maximum value: %d\n\n", sizeof(char), CHAR_MIN, CHAR_MAX);
  
  //signed char data type
  printf("**signed char**\nStorage size: %d byte \t Minimum value: %d \t Maximum value: %d\n\n", sizeof(signed char), SCHAR_MIN, SCHAR_MAX);
  
  //unsigned char data type
  printf("**unsigned char**\nStorage size: %d byte \t Maximum value: %d\n\n", sizeof(unsigned char), UCHAR_MAX);
  
  //int data type
  printf("**int**\nStorage size: %d bytes \t Minimum value: %d \t Maximum value: %d\n\n", sizeof(int), INT_MIN, INT_MAX);
  
  //unsigned int data type
  printf("**unsigned int**\nStorage size: %d bytes \t Maximum value: %d\n\n", sizeof(unsigned int), UINT_MAX);
  </code></pre>
  
  <p>}</p>
  
  <p>Am I omitting a detail or misunderstanding something?</p>