Editorial for Благозвучни Думи


Remember to use this editorial only when stuck, and not to copy-paste code from it. Please be respectful to the problem author and editorialist.

Submitting an official solution before solving the problem yourself is a bannable offence.
by:

Тестовете можете да видите тук.

Примерно решение на C++:

#include <iostream>
using namespace std;
int main ()
{
    char a,b,c,d; int br1=0, br2=0;
    cin>>a>>b>>c>>d;
    if(a=='a'||a=='o'||a=='e'||a=='i'||a=='u'||a=='y') br1++;
    else br2++;
    if(b=='a'||b=='o'||b=='e'||b=='i'||b=='u'||b=='y') br1++;
    else br2++;
    if(c=='a'||c=='o'||c=='e'||c=='i'||c=='u'||c=='y') br1++;
    else br2++;
    if(d=='a'||d=='o'||d=='e'||d=='i'||d=='u'||d=='y') br1++;
    else br2++;
    if(br1==br2)cout<<"Yes"<<endl;
    else cout<<br1<<' '<<br2<<endl;
    return 0;
}

Comments

There are no comments at the moment.