11. System Limitations
limits.h - constants for min,max of integer data typesfloat.h - constants for min,max,etc. of floating-point data types
Try chapter2_5.c
Compare float with double:
#include <stdio.h>
int main( void)
{
float f = 1.0/3.0; double d = 1.0/3.0;
printf( " float 1/3 = %.20g\n", f);
printf( "double 1/3 = %.20g\n", d);
return 0;
}
/* output: (shows 7 digits accurate for float, 16 for double)
float 1/3 = 0.3333333432674407959
double 1/3 = 0.33333333333333331483
*/