c test if string contains code example Example: check if string in string c if(strstr(sent, word) != NULL) { /* ... */ }