Advertisement
flaviucristi01

VARIANTA 79

Nov 17th, 2019
115
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
C++ 0.54 KB | None | 0 0
  1. #include <iostream>
  2. #include <cstring>
  3.  
  4. using namespace std;
  5.  
  6. char a[105],x[250];
  7.  
  8. int main()
  9. {
  10.     int i,c=0,t=0;
  11.     cin.getline(a,105);
  12.     for(i=0;i<strlen(a);i++)
  13.     {
  14.         if(strchr("aeiouAEIOU",a[i])!=0)
  15.         {
  16.             c++;
  17.             x[t]=a[i];
  18.             t++;
  19.             x[t]='*';
  20.             t++;
  21.         }
  22.         else
  23.         {
  24.             x[t]=a[i];
  25.             t++;
  26.         }
  27.     }
  28.     if(c!=0)
  29.     {
  30.         cout<<x;
  31.     }
  32.     else
  33.     {
  34.         cout<<"FARA VOCALE";
  35.     }
  36.     return 0;
  37. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement