#include<stdio.h>
#include<math.h>
double hypotenuse(double a,double b);
int main()
{
double a,b,f;
printf("Please enter the length of both sides:");
/*scanf("%f","%f",&a,&b);*/
scanf("%f",&a);
scanf("%f",&b);
f= hypotenuse(a,b);
printf("The hypotenuse of a triangle is %f",f);
return 0;
}
double hypotenuse(double c,double d)
{
double e;
e=sqrt(c*c+d*d);
return e;
}
结果一直是0.0000