The length function returns an integer for the number of fields bound to a multifield value or the length in characters of a string or symbol.
Syntax
(length <string-symbol-or-multifield-expression>)
If the argument given to length is not the appropriate type, a negative one (1) is returned. This function may also be called using the name length$.
Example
CLIPS> (length (create$ a b c d e f g)) 7 CLIPS> (length "cat") 3 CLIPS>