#include<stdio.h>#include<math.h>#define YOUXIAO 0.000001 void main() {float total,value; total=0.0; printf("请输入任意个数的实数,输入0结束输入过程\n"); scanf("%f",&value); while(fabs(value-YOUXIAO)>1e-5) {total+=value; scanf("%f",&value); } printf("the total is %f.\n",total); }