To tylko jedna z 2 stron tej notatki. Zaloguj się aby zobaczyć ten dokument.
Zobacz
całą notatkę
Strpbrk char *strpbrk(const char *s1, const char *s2); strpbrk scans a string, s1, for the first occurrence of any character appearing in s2 On success, strpbrk returns a pointer to the first occurrence of any of the characters in s2 If none of the s2 characters occur in s1, it returns NULL #include #include int main(void) { char *string1 = "abcdefghijklmnopqrstuvwxyz"; char *string2 = "onm"; char *ptr; ptr = strpbrk(string1, string2); if (ptr) printf("strpbrk found first character: %c\n", *ptr); else printf("strpbrk didn't find character in set\n"); return 0; } /* strpbrk found first character: m */
... zobacz całą notatkę
Komentarze użytkowników (0)