D
Dan M
Can anyone help me with this code?
This is the section and it comes up with a warning C4518: 'int' :
storage-class or type specifier(s) unexpected here; ignored on line 3
int replace (char *string)
int i= 0;
int total= 0;
while (*string)
{
if (*string+i)== ' '
{
total++;
*(string+i) '-';
}
i++
}
return total;
Any help gratefully appreciated!
Dan
This is the section and it comes up with a warning C4518: 'int' :
storage-class or type specifier(s) unexpected here; ignored on line 3
int replace (char *string)
int i= 0;
int total= 0;
while (*string)
{
if (*string+i)== ' '
{
total++;
*(string+i) '-';
}
i++
}
return total;
Any help gratefully appreciated!
Dan