1
0

defines.c 619 B

1234567891011121314151617
  1. // defines.c -- uses defined constants from limit.h and float.
  2. #include <stdio.h>
  3. #include <limits.h> // integer limits
  4. #include <float.h> // floating-point limits
  5. int main(void)
  6. {
  7. printf("Some number limits for this system:\n");
  8. printf("Biggest int: %d\n", INT_MAX);
  9. printf("Smallest long long: %lld\n", LLONG_MIN);
  10. printf("One byte = %d bits on this system.\n", CHAR_BIT);
  11. printf("Largest double: %e\n", DBL_MAX);
  12. printf("Smallest normal float: %e\n", FLT_MIN);
  13. printf("float precision = %d digits\n", FLT_DIG);
  14. printf("float epsilon = %e\n", FLT_EPSILON);
  15. return 0;
  16. }