#include <stdio.h>
int main() {
char str[100], *ptr;
int vowels=0;
printf("Enter a string: \n");
scanf("%s",str);
ptr=str;
while(*ptr!='\0'){
if(*ptr=='a'||*ptr=='e'||*ptr=='i'||*ptr=='o'||*ptr=='u'){
vowels++;
}
ptr++;
}
printf("number of vowels : %d",vowels);
return 0;
}
To embed this project on your website, copy the following code and paste it into your website's HTML: