char s[] = "ab-cd:ef;gh:i-jkl;mnop;qrs-tu:vwx-y;z"; char *delim = "-:" char *p; printf("%s/n", strtok(s, delim)); while((p = strtok(NULL, delim))) printf("%s/n", p);
输出: ab cd ef;gh i jkl;mnop;qrs tu vwx y;zint strcmp(const char *str1, const char *str2);int stricmp(const char *str1, const char *str2);int strncmp(const char *str1, const char *str2, size_t count);int strnicmp(const char *str1, const char *str2, size_t count);比较字符串大小。新闻热点
疑难解答