Posts

Showing posts from September, 2018

PrintVowels

#include <stdio.h> #include <stdlib.h> int check_vowel(char); int main() {    char s[100],t[100];    int i,j=0;    printf("Enter any string:\n");    scanf("%[^\n]s",&s);    for(i=0;s[i]!='\0';i++){     if(check_vowel(s[i]==0))     {t[j]=s[i];j++;}    } t[j]='\0'; printf("%s",t);     return 0; } int check_vowel(char c){ switch(c) {     case 'a':     case 'A' :     case 'e':     case 'E':     case 'i':     case 'I':     case 'o':     case 'O':     case 'u':     case 'U':     case ' ':     return 0;     default:         return 1; } }