C++ program to check vowel or consonant using if else

C++ program to check vowel or consonant using if else. Check the word is vowel or Consonant in C++ programs. This program will check the word whether it is vowel or consonant in C++. Checking the word is vowel or consonant in c++ program and print the whether the letter is vowel or not 

#include <stdio.h>
int main() 
{
char c;
int small, large;
printf("Enter the letter");
scanf("%c", &c);
small = (c == 'a' || c == 'e' || c == 'i' || c == 'o' || c == 'u');
large = (c == 'A' || c == 'E' || c == 'I' || c == 'O' || c == 'U');
if (small || large)
printf("%c is a vowel", c);
else
printf("%c is a consonant", c);
return 0;
}

Output:

Enter the letter

f

f is a consonant