Discussion: The STRIP function strips leading and trailing blanks from a string expression. The resulting current length of the string is adjusted accordingly.
The string-argument may be a string constant, a single-element string variable, a string array element, a string expression, or a string function.
See STRIPL and STRIPR.
Example 1: A$=STRIP(B$)
In the above example, the data contained in string variable B$ is stripped of leading and trailing blanks. The result is moved to the string variable A$.
INPUT OPTION$ IF STRIP(OPTION$) = "Y" THEN GOTO SectionTwo
In this example, the variable OPTION$ is used to receive input from the video screen. Next, leading and trailing blanks are stripped from the variable and the result is compared to "Y". If the result equals "Y" the program branches to statement label SectionTwo.