思路:因为保证了数据合法,所以可以认为每个V前都有一个C,在这个C前面断,特判一下开头不断就搞定了……?不知道思路有没有问题Orz
样例可过
#include<bits/stdc++.h>
using namespace std;
int main() {
int t, n;
cin>>t;
string a;
for (int time = 0; time < t; time++) {
cin>>n>>a;
cout<<a[0]<<a[1];
for (int i = 3; i < n; i++) {
if (a[i] == 'a' || a[i] == 'e') {
cout<<'.';
}
cout<<a[i-1];
}
cout<<a[n-1]<<endl;
}
return 0;
}