W.A.P. C++

WAP | CPP | Programs in C++ | C++ Solutions

Snehil Khanor's Binary Log

Write a program to store a character and check it is vowel or consonant


A character is taken from user.. and is checked if it is a vowel or a consonant..
Select To use this code as it is.. select and copy paste this code into code.cpp file :)
  1. #include<iostream.h>
  2. #include<conio.h>
  3. void main()
  4. {
  5. clrscr();
  6. //Coding by: Snehil Khanor
  7. //http://WapCPP.blogspot.com
  8. char x;
  9. cout<<"Please enter a character: ";
  10. cin>>x;
  11. if(x=='a'||x=='A'||x=='e'||x=='E'||x=='i'||x=='I'||x=='o'||x=='O'||x=='u'||x=='U')
  12. cout<<x<<" is a Vowel :)";
  13. else
  14. cout<<x<<" is a consonant :)";
  15. getch();
  16. }

0 comments:

Search

About WAP C++

Here you'll find a wide range of programs' solution ranging from beginer level to advanced level.
All programs here are made, compiled and tested by me..and are running absolutely fine.. still if you find any bug in any program do let me know :)

Followers

Subscribe via email

Enter your email address:

Delivered by FeedBurner

my Binary Log

Blog Archive



eXTReMe Tracker