ANTIC VOL. 4, NO. 1 / MAY 1985 / PAGE 26
Infrequently Used BASIC Commands
STR$ - In BASIC, the STR$ command converts a number or numeric
variable to a STRing. You will also need a string variable name to place
the string into if you want to use it somewhere else. ONE23$ = STR$(123)
will assign the string "123" to the string variable ONE23$.
VAL - In BASIC, VAL performs the opposite function as STR$.
VAL converts a string which is made of numeric characters to a numerical
variable or value. X=VAL(Y$) will assign the value of 123 to the variable
X if Y$ were a string called "123". If Y$ is an alphabetic character, an
error will result.