strlen

Finds the length of a character string

#include <strings.h>
long strlen (
        const char *s
)

Arguments

s Pointer to a character string

Return Value

The length of the string pointed to by s is returned.

Explanation

The length of the string pointed to by s (i.e. the number of characters in the string) is obtained and its value is returned.