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