Prerequisite:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 |
#include<stdio.h> int main() { unsigned char ch; printf("\n Program to check Whether Vowel or Consonant"); printf("\nPlease enter any Alphabets: "); scanf("%c",&ch); if(((ch>='a')&&(ch<='z'))||((ch>='A')&&(ch<='Z'))) { printf("\n Entered Character is Alphabet"); } else { printf("\n Entered Character is Not an Alphabet"); } return 0; } |
1 2 3 4 5 |
Output: Program to check Whether Vowel or Consonant Please enter any Alphabets: a Entered Character is Alphabet |