#include<stdio.h>
#include<windows.h>
//若干人慈善捐款逐个相加,超过一万元时结束输出最后累加值
void test051()
{
//变量sum用来存放累加和
float amount, sum = 0;
printf("please enter a amount of a donation/输入一份捐赠款项金额:\n");
do
{
scanf("%f", &amount);
sum = sum + amount;
} while(sum < 10000);
printf("the total donation reached 100000,is ");
printf("%f",sum);
}
void main()
{
// test01();
// test02();
// test03();
// test04();
// test05();
test051();
system("pause");