初学者请教一个C语言问题!
我写了个程序,类似一个计算器加法,小数还会写。但一变成大数就超出double范围了,怎么办!?比如说9999999999999999+1111111111怎么弄啊!?这么大,进位着实不会了。
程序代码:一道简单的加法计算题
#include <stdio.h>
#include <math.h>
void main()
{
double a,b,c;
printf("please input first number:");
scanf("%lf",&a);
printf("please input second number:");
scanf("%lf",&b);
c=a+b;
printf("the num is: %lf \n",c);
}