#define _CRT_SECURE_NO_WARNINGS 1
#include<stdio.h>
int my_strlen(char* st)
{
int count = 0;
while (*st != '\0')
{
count++;
*st++;
}
return count;
}
int main()
{
char arr[] = "bit";
int len = my_strlen(arr);
printf("%d\n", len);
return 0;
}
标签:count,arr,自定义,int,st,char,字符串,长度,strlen From: https://blog.51cto.com/u_15838933/5798139