Showing posts with label Selection Questions. Show all posts
Showing posts with label Selection Questions. Show all posts

Check if the letter is vowel or consonant

C Program
#include <stdio.h>
#include <stdlib.h>
int main()
int main()
{
    char c;
    printf("Enter any word: ");
    scanf("%c",&c);
    if(c=='A'||c=='a'|| c=='E'||c=='e'||c=='I'||c=='i'||c=='O'||c=='o'||c=='U'||c=='u')
        printf("%c is a vowel",c);
    else
        printf("%c is a Consonant",c);
}