Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- /*case insensitive funkcia strstr*/
- char* mystrstr(char *seno, char *ihla){
- char *s, *i;
- if (!*ihla)
- return seno;
- for (; *seno; seno++){
- if (toupper(*ihla) == toupper(*seno)){
- s = seno;
- i = ihla;
- while (*i && *s){
- if (toupper(*i) != toupper(*s))
- break;
- i++;
- s++;
- }
- if (!*i)
- return seno;
- }
- }
- return NULL;
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement