jumby 的 站内主页
#include<stdio.h>
void main()
{
float a ,b;
a=123456.789e5;
b=a+20;
printf("%f\n",b);
}
问题:
(1)得出的结果让我很迷糊,是“12345678848.000000”。这个数怎么得出来的?!
(2)书上说一个float只能保证有的有效数字是7位,是前七位吧?!那后面的怎么办呢?!....
Read More >
2009
07-04
07-04
float的有效数字是6~7位,请问这个“6~7”是什么意思?如果说一个float型只有4位数,如“1234”,那它用十进制表示的话是“1234.000”吗?
谢谢指教........
Read More >
我刚学C,用的编译器是TC2.0,可我按书上写的最简单的:
#include<stdio.h>
void main()
{
printf("This is a C program.\n");
}
可总是提示"Error:Unable to open include file’STDIO.H’"
这是怎么回事啊?!
谢谢指教........
Read More >