-->
当前位置:首页 > 题库

PROGRAMMING:Victory in anti epidemic

Luz5年前 (2021-05-10)题库499
After the outbreak of the epidemic in Wuhan, the medical team of Henan Province rushed to the front line of Wuhan to fight against the epidemic. They practiced the lofty professionalism of medical staff to save the dying and heal the wounded with their own actions. On March 19, the people from all walks of life in the province met the anti epidemic heroes and returned safely. Day and night in Wuhan, they went into the shelter hospital and contacted the patients closely for treatment. The team members were not afraid of sacrifice, hardship and tiredness. They charged and fought on the front line of fighting against the epidemic. Many moving deeds happened. In this battlefield without gunsmoke, they were all brave soldiers. They had to move forward without fear.
Let's use programming to record the names of these heroes and pay the highest respect to them!
![ Wechat pictures_ 20200322100449.jpg](~/cbcac409-24e1-4487-9edc-50e929930068.jpg)
(picture from news:[ https://view.inews.qq.com/a/20200319A0HYD400? chlid=news_ news_ top&devid=ecad4b824f34ecbf&qimei=862522041936600&shareto=moments&from=timeline])
###Input format:
Several line strings. Each line contains a string representing the name of the hero in pinyin, which is no more than 20 characters long.
This question needs to use how to judge the end of the input file. If you read one integer at a time until the end of the file, you can use the following example:
```
int a;
while (scanf("%d", &a) != EOF)
{
}
```
###Output format:
How many anti epidemic heroes are on the current list.
###Input example:
```in
Wang Yaoping
Zhu Shengyong
Cu Zidong
Zhou Zheng
```
###Output example:
```out
four
```







answer:If there is no answer, please comment
```
/*
* @Description:
* @Author: Wu Yunpeng
* @Date: 2020-03-22 10:22:46
*/
#include
using namespace std;
typedef long long ll;
typedef unsigned long long ull;
#define mem(s) memset(s, 0, sizeof(s))
const int INF = 0x3f3f3f3f;
const double eps = 1e-8;
const int maxn = 1e6+5;
const int mod = 998244353;
int main()
{
int sum = 0;
string str;
while(getline(cin, str))
{
sum++;
}
cout << sum <return 0;
}
```