Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- #include <iostream>
- using namespace std;
- int main()
- {
- string a;
- int b=0,g=0;
- cin >> a;
- //cout<<g;
- for(int i=1;i<a.length();i++)
- {
- //cout<<i<<" ";
- if((a[i]!=('a') && a[i-1]!=('a'))&& (a[i]!=('e') && a[i-1]!=('e')) && (a[i]!=('i') && a[i-1]!=('i')) && (a[i]!=('o') && a[i-1]!=('o')) && (a[i]!=('u') && a[i-1]!=('u')))
- {
- //cout<<a[i-1]<<" "<<a[i];
- b++;
- }
- }
- cout<<b;
- return 0;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement