Write a program that inputs a sequence of characters and outputs the number of vowels..!! Its not working.!!
if anyone can guide.!!
Code:
#include<iostream.h>
#include<conio.h>
int isVowel (char x);
int main()
{
char word;
int count=0,i;
clrscr();
cout<<"Enter sequence of characters";
cin>>word;
i=isVowel(word);
if (i==1)
{
count++;
cout<<count<<endl;
}
else
{
cout<<"No Vowels";
getch();
return 0;
}
{
char a,e,i,o,u,x;
if (x=='a')
{
return 1;
}
if (x=='e')
{return 1;
}
if (x=='i')
{return 1;
}
if (x=='o')
{return 1;
}
if (x=='u')
{return 1;
}
}
{
return 0;
}
}