C库函数 strlen()

Python/Java学习交流群:369606713


C库函数 strlen()

#include <stdio.h>

#include <string.h>



int main () {

   char str[50];

   int len;



   strcpy(str, "This is codingdict.com");



   len = strlen(str);

   printf("Length of |%s| is |%d|\n", str, len);



   return(0);

}