
#include <stdio.h>
int main() {
struct Student {
float high;
char sex;
} stu[5];
int i;
float s = 0;
for (i = 0; i < 5; i++) {
scanf("%f%c", &stu[i].high, &stu[i].sex);
s += stu[i].high;
}
printf("平均身高为%f", s / 5);
return 0;
}




中级程序员
by: LinKin 发表于:2019-10-28 09:43:01 顶(0) | 踩(0) 回复
运用到实际,优秀
回复评论