Easy soluton in c++


#1

int Solution::solve(string A) {

if(A.length()==0)
{
    return 0;
}

int count=0;

for(int i=0;i<A.length();i++)
{
      if(A[i]=='a'||A[i]=='e'||A[i]=='i'||A[i]=='o'||A[i]=='u'||A[i]=='A'||A[i]=='E'||A[i]=='I'||A[i]=='O'||A[i]=='U') 

    for(int j=i; j<A.length(); j++)
    {
        count++;
    }
       
     

}


return (count%10003);

}