references/sleep-functions/strlen.md

GitHub

strlen

Category: Strings

Source: https://sleep.dashnine.org/manual/strlen.html


Synopsis

$ strlen("string")

Returns the length of the specified string.

Parameters

"string" - the string to obtain the length of.

Returns

A scalar integer

Examples

Example:

$string = "this is some text";
$length = strlen($string);

println($length);

Output:

17

See Also

&byteAt; &charAt; &left; ∣ &right; &substr