[QUOTE=hardik]
Quote:
Originally Posted by hardik
ok here is the code i made
Code:
#include <string.h>
int main (void)
{
char *foo = " Charlotte *NC*is*a*really*cool*place*to*work*and*play";
char delims[]="*";
char *result = NULL;
result = strtok ( str, delims );
while ( result != NULL )
{
printf ("result is "\%s"\n", result );
result = strtok (NULL, delims );
}
return 0;
}
can someone please explain what is wronge with it?