Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- int main()
- {
- char a[40];
- int b,c,d,e,max;
- b=c=d=e=max=0;
- cout << "vvedite stroku: ";
- cin.getline(a,40);
- while (a[b]!='\0')
- {
- while (a[b]>='A' && a[b]<='Z' || a[b]>='a' && a[b]<='z')
- {
- b=b+1;
- c=c+1;
- d=b;
- }
- if (c>max)
- {
- max=c;
- e=d-max;
- }
- c=0;
- b=b+1;
- }
- while (c<max)
- {
- cout << a[e];
- e=e+1;
- c=c+1;
- }
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement