/*write a c program to find the length of the string using strlen() function*/
#include 'stdio.h'
#include ' string.h '
void main()
{
char name[100];
int length;
printf(“Enter the string”);
gets(name);
length=strlen(name);
printf(“\nNumber of characters in the string is=%d”,length);
}
Example: length=strlen(“Hollywood”);The function will assign number of characters 9 in the string to a integer variable length.