diff --git a/Basic/Check Whether a Character is Vowel or Consonant/SolutionByBavleen.cpp b/Basic/Check Whether a Character is Vowel or Consonant/SolutionByBavleen.cpp new file mode 100644 index 000000000..e080f4474 --- /dev/null +++ b/Basic/Check Whether a Character is Vowel or Consonant/SolutionByBavleen.cpp @@ -0,0 +1,17 @@ +#include + +int main() { + char value; + std::cout<<"enter the character you want to check? "; + std::cin>>value; + if(value == 'a' || value == 'e' || value == 'i' || value == 'o' || value == 'u' || value == 'A' || value == 'E' || value == 'I' || value == 'O' || value == 'U') + { + std::cout << "It is a Vowel"; + } + else + { + std::cout << "It is a consonent"; + } + + return 0; +}