View Code of Problem 3496

    #include <stdio.h>
    #include <string.h>
    int main(){
      char s[1000];
      while(gets(s)!=NULL){
        int len =strlen(s);
        for(int i=0;i<len;i++){
          if(s[i]=='y'&&s[i+1]=='o'&&s[i+2]=='u'){
            printf("we");
            i=i+2;
          }else{
            printf("%c",s[i]);
          }
        }
        printf("\n");
      }
    }

Double click to view unformatted code.


Back to problem 3496