Vowels or not in C


In this example, you will learn to check whether an alphabet entered by the user is a vowel or a consonant.

Source Code

/*
Write a program to find the given character is  vowels or not
using switch case. aeiou
*/
 
#include<stdio.h>
 
int main()
{
 char c;
 printf("\nEnter The Character : ");
 scanf("%c",&c);
 switch(c)
 {
 case 'a':
 case 'e':
 case 'i':
 case 'o':
 case 'u':
 case 'A':
 case 'E':
 case 'I':
 case 'O':
 case 'U':
    printf("%c is a Vowel",c);
    break;
 default:
    printf("%c is not a Vowel",c);
    break;
 }
 return 0;
}
 
To download raw file Click Here

List of Programs


Sample Programs


Switch Case in C


Conditional Operators in C


Goto Statement in C


While Loop Example Programs


Looping Statements in C

For Loop Example Programs


Array Examples in C

One Dimensional Array


Two Dimensional Array in C


String Example Programs in C


Functions Example Programs in C


Learn All in Tamil © Designed & Developed By Tutor Joes