这个为什么一直输出0.000000
#include<stdio.h>
int main()
{
int sex;
float moHeight,faHeight,Height1,Height2,Height3;
char judge1,judge2;
printf("please input moHeight,faHeight,your child's sex 1 boy/0 girl\n");
scanf("%f,%f,%f",&moHeight,&faHeight,&sex);
switch(sex)
{
case1:Height1=(faHeight+moHeight)*0.54;break;
case0:Height1=(faHeight*0.923+moHeight)/2;
}
printf("if you love sports Y/N\n");
getchar();
scanf("%c",&judge1);
switch(judge1)
{
case'Y':Height2=1.02*Height1;break;
}
printf("if you have a healthy diet Y/N\n");
getchar();
scanf("%c",&judge2);
switch(judge2)
{
case'Y':Height3=1.015*Height2;break;
}
printf("your child's height is %f",Height3);
return 0;
}