Advertisement
IlincaMuresan

5

Nov 19th, 2019
113
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.35 KB | None | 0 0
  1. #include<iostream>
  2. #include<cstring>
  3. #include<climits>
  4. using namespace std;
  5. char x[256];
  6.  
  7. int main()
  8. {
  9. int n,i;
  10. cin>>n;
  11. int m;
  12.  
  13.  
  14. int lMax=INT_MIN;
  15. for(i=1; i<=n; i++)
  16. {
  17. cin>>x;
  18.  
  19. m=strlen(x);
  20. if(m>lMax)
  21. {
  22. lMax=m;
  23. }
  24. }
  25. cout<<lMax;
  26. return 0;
  27. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement