# CountStringTokens

## Description

Counts the number of tokens separated by a specified set of delimiters, for example a string containing "first:second:third" has three tokens delimited by ":" and "first:second;thrid" has three tokens separated by the delimiters ":;". You can have multiple delimiters between each token, for example "first:;second:third" is valid, and has three tokens. This command is useful for separating words in a sentence, which can be delimited by both white space and punctuation.

## Definition

integer CountStringTokens( str, delimiters )

int agk::CountStringTokens( const char* str, const char* delimiters )

## Parameters

- str - The string to check.
- delimiters - The set of characters that delimit the string