You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
25 lines
390 B
25 lines
390 B
#include<iostream>
|
|
using namespace std;
|
|
int main()
|
|
{
|
|
int boy,girl,sum;
|
|
cout<<"请输入男女生的人数:"<<endl;
|
|
cin>>boy>>girl;
|
|
cout<<"男生人数为:"<<boy<<endl;
|
|
cout<<"女生人数为:"<<girl<<endl;
|
|
sum=boy+girl;
|
|
if(sum<13)
|
|
{
|
|
cout<<"接受的任务为送水"<<endl;
|
|
}
|
|
else if(sum>=13 && boy>girl)
|
|
{
|
|
cout<<"接受的任务为种树"<<endl;
|
|
}
|
|
else {
|
|
cout<<"接受的任务为采茶"<<endl;
|
|
}
|
|
return 0;
|
|
}
|
|
|