i need a program to remove commas from a string.can anyone help? tks chan
string
Collapse
X
-
Originally posted by chandru50i need a program to remove commas from a string.can anyone help? tks chan
main()
{
char *input, output[50];
int i;
/*"input" point to the required string
So make the "input" pointer point to the input string*/
printf(" input val = %s\n", input);
while(*input != '\0')
{
if(*input != ',')
{
output[i]=*input;
i++;;
input++;
}
else
input++;
}
printf("output val %s\n",output);
}
See if this help you......
Comment