有理数集的基数是什么,它有一个与IEEE-754兼容的浮点格式的精确表示?
发布于 2014-06-23 15:24:27
有2139095039个有限正浮子。有许多有限的负浮子。
您希望将+0.0和-0.0作为两个项还是作为一个项?根据答案,总数为2* 2139095039 +2或2* 2139095039 + 1,即分别为4278190080或4278190079。
2139095039号码的资料来源:
#include <float.h>
#include <math.h>
#include <stdlib.h>
#include <stdio.h>
#include <string.h>
int main(void) {
float f = FLT_MAX;
unsigned int i;
memcpy(&i, &f, 4);
printf("%u\n", i);
}https://stackoverflow.com/questions/24369558
复制相似问题