c语言问题
#include<iostream>#include<cmath>
using namespace std;
int main()
{double a,b,c,s,t;
scanf("%f%f%f",&a,&b,&c);
if(a+b>c&&a+c>b&&b+c>a)
{s=(a+b+c)*0.5;
t=sqrt(s*(s-a)*(s-b)*(s-c));
cout<<t<<endl;}
else
cout<<"its not a triangle!"<<endl;
return 0;}
}输入 4,5,6输出its not a triangle,为啥,该为scanf("%lf%lf%lf",&a,&b,&c)得到正确的结果,想知道他们的为啥不同