$countTokens

Returns the number of tokens of a string separated by the given delimiter.
Syntax
    $countTokens{string}{delimiter_char}
DocumentationThe function countTokens returns the count of tokens in parameter 1 where parameter 2 specifies the delimiters which default to "\r\n\t"
Returns the number of tokens contained in a string delimited by the given delimiter character:

    Parameter:
      string, the string to be tokenized
      delimiter_char, a delimiter character. This argument is optional and defaults to '\r\n\t'
    Returns:
      the number of tokens contained in the string after tokenizing it using the specified delimiter.
Examples
Get the number of tokens of some string:

    $set{string}{a - b - c}
    $set{tokens}{$getTokens{$get{string}}{-}}
    $//The value of tokens should be 3
    $set{tokens}{$getTokens{$get{string}}{$\ }}
    $//The value of tokens should be 5
Get the number of accounts:

    $set{accounts}{$countTokens{$account{list}}{$\ }}
GroupString
Minimum required transaction-mode:NONE
Required scripting permission of the developerPERMISSION_FL_BASIC
Minimum parameters1
Maximum parameters 2