링크 : https://www.acmicpc.net/problem/4659
#include <iostream>
#include <string>
#include <vector>
using namespace std;
int main(){
string s = "";
while(1){
cin >> s;
if(s == "end") break;
bool isAccept = true;
vector<bool> isVowel(s.size());
int cntV = 0;
for(int i = 0; i < s.size(); i++){
if(s[i] == 'a' || s[i] == 'e' || s[i] == 'i' || s[i] == 'o' || s[i] == 'u'){
cntV++;
isVowel[i] = true;
}
else isVowel[i] = false;
}
for(int i = 2; i < s.size(); i++){
if(isVowel[i] == isVowel[i-1] && isVowel[i-1] == isVowel[i-2]){
isAccept = false;
break;
}
}
for(int i = 1; i < s.size(); i++){
if(s[i] != 'e' && s[i] != 'o' && s[i] == s[i-1]){
isAccept = false;
break;
}
}
if(cntV == 0) isAccept = false;
if(!isAccept) cout << "<" << s << ">"<< " is not acceptable." << endl;
else cout << "<" << s << ">"<< " is acceptable." << endl;
}
return 0;
}