What it does
Str takes valueInt (an integer), and answers a string. That is the first of 3 forms.
Syntax
1
Str(valueInt integer) → string2
Str(valueFloat float) → string3
Str(valueFloat float, decimals integer) → stringParameters
| Name | Type | In forms |
|---|---|---|
| valueInt | integer | 1 |
| valueFloat | float | 2, 3 |
| decimals | integer | 3 |
Every form returns
string
Example · generated
Form 1, the short one
DO Print(Str(1)) Sync()LOOPForm 3, with every argument
DO Print(Str(1.0, 1)) Sync()LOOPStr is called and its answer is printed every frame. The DO … LOOP is not decoration: a classic BASIC program ends the moment it runs out of lines, and Sync() is what draws the frame.