← 返回列表

浮点类型

浮点类型 #include <stdio.h> #include <float.h> int main() { printf("Storage size for float : %d \n", sizeof(float)); printf("Minimum float positive value: %E\n", FLT_MIN ); printf("Maximum float positive value: %E\n", FLT_MAX ); printf("Precision value: %d\n", FLT_DIG ); return 0; }

浮点类型

#include <stdio.h>

#include <float.h>



int main() {



   printf("Storage size for float : %d \n", sizeof(float));

   printf("Minimum float positive value: %E\n", FLT_MIN );

   printf("Maximum float positive value: %E\n", FLT_MAX );

   printf("Precision value: %d\n", FLT_DIG );



   return 0;

}

打开资源 ↗

交流与评论