C Tutorial/string.h/strlen

Материал из C\C++ эксперт
Перейти к: навигация, поиск

strlen

Item Value Header file string.h Declaration size_t strlen(const char *str); Return returns the string length. The null terminator is not counted.


<source lang="cpp">#include<string.h>

  1. include<stdio.h>

int main(void){

  printf("%d", strlen("hello"));

}</source>