Advertisement
ioanaasdfgh

v72 grile siruri

Nov 15th, 2018
97
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.24 KB | None | 0 0
  1. #include <iostream>
  2. #include <string.h>
  3.  
  4. using namespace std;
  5.  
  6. int main()
  7. {
  8.     int i;
  9.    char s[25],x[25];
  10.    cin.get(s,25);
  11.    cin.get();
  12.    for(i=0;i<strlen(s);i++)
  13.     if(strcmp(x,s+i)<0)
  14.         strcpy(x,s+i);
  15.  
  16.    cout<<x;
  17. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement