Seems misleading since strlen() does not work with cstring, one must use
x.length() instead.
No strlen() requires a C-string while x.length() would require a std::string. The <cstring> header defines functions used to operate on C-strings, while <string> defines the C++ string class.
Also the <string.h> include is the C standard header and <cstring> is the C++ standard header that provides the same functions as <string.h>