delete pics to save space
This commit is contained in:
20
history_source/信息学奥赛一本通/1.5.3.20.cpp
Normal file
20
history_source/信息学奥赛一本通/1.5.3.20.cpp
Normal file
@ -0,0 +1,20 @@
|
||||
#include<iostream>
|
||||
#include<string>
|
||||
using namespace std;
|
||||
int main()
|
||||
{
|
||||
string max,maxn;
|
||||
char w;
|
||||
while(w=getchar(),w!='\n'&&w!='.')
|
||||
{
|
||||
if(w==' ')
|
||||
{
|
||||
if(maxn.size()>max.size()) max=maxn;
|
||||
maxn="";
|
||||
}
|
||||
else maxn+=w;
|
||||
}
|
||||
if(maxn.size()>max.size()) max=maxn;
|
||||
cout<<max<<endl;
|
||||
return 0;
|
||||
}
|
Reference in New Issue
Block a user