View Code of Problem 55

#include<stdio.h>
#include<string.h>
int main(){
	int len,i;
	char str[100];
	char  c[2] ;
	//gets(c);
	
	scanf("%s",str);
	scanf("%s",c);
	
	//scanf("%c",&c);
	//printf("%s",str);
	i = 0;  
	while(str[i]!='\0'){
		if(str[i]==c[0]) 
			str[i] = str[i+1];
			//printf("%c",str[i]);
		i++;
	} 
	printf("%s",str);

	return 0 ;
}

Double click to view unformatted code.


Back to problem 55