Function (Path Standard C Header / string.h)

strcspn

size_t strcspn(char *s, char *charset);

Retrieve several consecutive characters at the beginning of the string s that do not contain the characters in the string charset


Parameters

  char *s
    String s

  char *charset
    Char set string

函数 (属于 标准C头文件 / string.h)

strcspn

size_t strcspn(char *s, char *charset);

检索字符串 s 开头连续有几个字符都不含字符串 charset 中的字符


参数

  char *s
    字符串s

  char *charset
    字符集合串