Yes, and as far as substrings, well, you are going to have to split them up yourself! The function might have this signature:
Code:
/*...returns false at end of string...*/
bool GetNextWord( char sentence[], int * next_position, char recieve_buff);
int main() {
char sentence[] = "This string will get parsed";
char parsed[] = "parsed";
char word[100];
int next = 0;
while( GetNextWord( sentence, &next, word ) ) {
printf("\n%s", word);
if( strcmp(word, parsed) == 0) {
printf(" matches %s.", parsed);
getch();
}
return 0;
}