STR$()

From Liberty BASIC Family
Jump to navigation Jump to search
Supported in Just BASIC Supported in Liberty BASIC Not supported in Liberty BASIC 5 Not supported in Run BASIC

Description

Returns the string representation of a number or number expression.
See also VAL() for the opposite function.

Syntax

  1. str$(number)

Hints

Although STR$() is required when concatenating numeric values with string values using the + (plus) operator, it is more direct to use the ; (semi-colon) to combine those values and omit the STR$() from the statement. These 2 statements will provide the same result:
a$="My string is attached to " + str$(5) + " numbers."
print a$
and
a$="My string is attached to "; 5; " numbers."
print a$

Example

' Place a simple, working example of the keyword here

Useful Procedures

' Place a useful function or sub using this keyword here