#include<stdio.h>
#include<stdlib.h>
#include<string.h>
void main()
{
float add(float x,float y);
float a,b,c;
printf("Please enter a and b:");
scanf_s("%f,%f",&a,&b);
c=add(a,b);
printf("sum=%f",c);
system("pause");
}
float add(float x,float y)
{
float z;
z=x+y;
return(z);
}
(C)输入两个实数,用函数求它们的和
最新推荐文章于 2023-10-12 16:24:59 发布