题解 | #判断是元音还是辅音#
判断是元音还是辅音
https://www.nowcoder.com/practice/7eb4df4d52c44d309081509cf52ecbc4
#include <stdio.h> int main() { char a; while ((a = getchar()) != EOF) { if( (a == 'a') || (a =='A') || (a =='e') || (a =='E') || (a =='i') || (a =='I') ||(a =='o') || (a =='O') || (a =='u') || (a =='U')) printf("Vowel\n"); else printf("Consonant\n"); getchar();//注意\n也是个字符,要将其吃掉才行。 } return 0; }