Answers for "c how to check if char in string"

C
4

check if string in string c

if(strstr(sent, word) != NULL) {
    /* ... */
}
Posted by: Guest on February-23-2020
1

c check if char is an operator

char o = '+';	//Or some other character

if (o == '%' || o == '/' || o == '*' || o == '+' || o == '-') {
	//Do something
    //...
}
Posted by: Guest on June-09-2020

Code answers related to "c how to check if char in string"

Code answers related to "C"

Browse Popular Code Answers by Language