In this post, we will see how to check a Character is Vowel or Consonant.
You just need to check if character is part of set {a,A,e,E,i,I,o,O,u,U}.If it is part of set then it is Vowel else Consonant.
Output:
Enter an Alphabet : g
g is a Consonant
g is a Consonant
That’s all about Java Program to Check a Character is Vowel or Consonant.
Was this post helpful?
Let us know if this post was helpful. Feedbacks are monitored on daily basis. Please do provide feedback as that\'s the only way to improve.