#include <conio.h>
#include <stdio.h>
char phrase[50];
int count;
int cvowel();
void main()
{
clrscr();
printf("Enter a phrase :");
gets(phrase);
count = cvowel();
printf("The number of vowels are : %i\n",count);
printf("New Phrase :%s ",phrase);
getch();
}
int cvowel()
{
int value=0;
int index;
for(index= 0;index<0;index++);
{
if (((phrase[index] == 'a') || (phrase[index] == 'e')) ||
(phrase[index] == 'i') || (phrase[index] == 'o') ||
(phrase[index] == 'u'))
{
value++;
phrase[index]='X';
}
}
return value;
}
I cant make this program run on one full phrase but i can run with a single character...