Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- #include <string.h>
- using namespace std;
- const char gl[] = "aeiou";
- int main()
- {
- char vod[255] = {0};
- gets(vod);
- char rab[100][100] = {0};
- int an[100][2] = {0};
- int i, j, s = 0, c = 0;
- for (i = 0 ; vod[i] != 0 ; i++)
- {
- if (vod[i] == ' ')
- {
- c = 0;
- s++;
- continue;
- }
- rab[s][c++] = vod[i];
- }
- for (i = 0 ; i <= s ; i++)
- {
- for (j = 0 ; rab[i][j] != 0 ; j++)
- {
- if (rab[i][j]==gl[0]||rab[i][j]==gl[1]||rab[i][j]==gl[2]||rab[i][j]==gl[3]||rab[i][j]==gl[4]) an[i][0]++;
- else
- {
- if (rab[i][j]=='.') continue;
- else an[i][1]++;
- }
- }
- if (an[i][1] > an[i][0]) cout<<'$';
- cout<<rab[i]<<' ';
- }
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement