/**
* @date : 2011-11-02
* @author : MJN
* @function : count the number of characters(before '\0')
* @return : the number of characters
*/
size_t strLen(const char *str)
{
size_t len = 0;
while ((*str++) != '\0')
{
len++;
}
return len;
}
strlen函数的实现
最新推荐文章于 2022-03-10 13:08:09 发布