strtok() usage
Hello i was tried to use strtok() to make array of words but i can't
1 2 3 4 5 6
|
char** word = new char*[wordCount];
word[0] = strtok (str, " ,.!?");
for(int i=1;i<wordCount;i++)
word[i] = strtok (NULL, " ,.!?");
|
this is my code but its don't work. why ? can somebody help me pls.
don't start multiple threads about the same thing.
then how to count the words in this string ?
Topic archived. No new replies allowed.