Maybe this would work for you:
Code:int i;
int original_length; // <- needs to be set
for(i=0; i<original_length; i++)
if( line[i] == '\0')
line[i] = ' ';
Printable View
Maybe this would work for you:
Code:int i;
int original_length; // <- needs to be set
for(i=0; i<original_length; i++)
if( line[i] == '\0')
line[i] = ' ';
i did what you said but the \0 was still there because it did not print the second word.PHP Code:int original_length;
original_length= strlen(line);
for(i=0; i<original_length; i++)
if (line[i]=='\0')
line[i] = ' ';
i figured out the problem after some trial and error thanks for all the help.