Q. Check whether the given alphabet is vowel or consonant ?
THE OUTPUT WOULD BE
#include<stdio.h>
#include<conio.h>
void main( )
{ clrscr( );
char ch;
printf("Enter an aphabet=");
scanf("%c",&ch);
if(ch=='a'||ch=='e'||ch=='i'||ch=='o'||ch=='u')
{ printf("\nVowel");
}
else
{ printf("\nConsonant");
}
getch( );
}
No comments:
Post a Comment