std::strlen (3) - Linux Manuals
std::strlen: std::strlen
NAME
Synopsis
Defined in header <cstring>
std::size_t strlen( const char* str );
Returns the length of the given byte string, that is, the number of characters in a character array whose first element is pointed to by str up to and not including the first null character. The behavior is undefined if there is no null character in the character array pointed to by str.
Parameters
str - pointer to the null-terminated byte string to be examined
Return value
The length of the null-terminated string str.
Example
// Run this code
Output:
See also
wcslen (function)
mblen (function)