strlen: returns the string length : strlen « string.h « C / ANSI-C






strlen: returns the string length


    
  
//Declaration:  size_t strlen(const char *str); 
//Return:       returns the string length. The null terminator is not counted. 


  

#include<string.h>
#include<stdio.h> 

int main(void){
   printf("%d", strlen("hello"));
}

         
/*
5*/
           
       








Related examples in the same category