Start: Jun, 28, 2019 08:42:00
2019杭州师范大学第一届程序设计竞赛新生赛
End: Jun, 28, 2019 11:42:00
Time elapsed:
Time remaining:

Problem_ID: B
Result: Accepted
Time: 257ms
Memory: 1092kB
In contest: 1276

#include<stdio.h>
#include <string.h>

int main(){
	int t,i;
	int a,b,j,long1;
	char str[60];
	while(~scanf("%d",&t)){
		if(t>=1&&t<=100000){
			for(i=1;i<=t;i++){
				scanf("%s",&str);
				long1=strlen(str);
				a=0;
				b=0;
				if(long1>=1&&long1<=50){
					for(j=0;j<long1;j++){
						if(str[j]<'a'||str[j]>'z'){
							b=b+1;
						}
					}
					if(b==0){
						for(j=0;j<long1;j++){
							if(str[j]=='a'||str[j]=='e'||str[j]=='u'||str[j]=='i'||str[j]=='o'){
								a=a+1;
							}
						}
						printf("%d\n",a);
					}
				}
			}
		}
	}
}