Determine the Number of Spaces (or Other Characters) in an Answer
There may be times when you want to know how many spaces or other characters are contained in an answer. For example, by counting the number of spaces in an answer, you can determine how many words are in the answer. (The number of words is generally equivalent to the number of spaces, plus one.)
You can use the following computation to determine the number of spaces or other characters in an answer. The computation's result begins with a value of zero and each time a space is found, it is incremented by one. A temporary Text variable is initially set to the answer of the variable whose spaces you want to count. Then, as each space is found, all characters up to and including the space are removed from the temporary variable's answer. In the end, the computation's result is the number of spaces that were found.