#include<bits/stdc++.h> using namespace std; int main() { char s[256],b[256],a[256]={'\0'}; int i,j=0; gets(s); for(i=0;i<strlen(s);i++){ if(s[i]!=' '){ b[j]=s[i]; j++; if(s[i+1]==' '||s[i+1]=='\0'){ b[j]='\0'; if(strlen(b)>strlen(a)){ strcpy(a,b); }j=0; } } }cout<<a; return 0; } /************************************************************** Problem: 1107 User: houshanglin Language: C++ Result: Accepted Time:8 ms Memory:2076 kb ****************************************************************/