#include<stdio.h> int main() { char ch,ch1[100],ch2[200]; int i,j=0; scanf("%s",ch1); getchar(); scanf("%c",&ch); for(i=0;ch1[i]!='\0';i++) if(ch!=ch1[i]) { ch2[j++]=ch1[i]; } printf("%s",ch2); return 0; } |
Double click to view unformatted code.