Jump to navigation Jump to search
Usage: INPUT "Name, age and sex(M or F): ", nm$, age%, sex$
- Commas in PRINT statements TAB space values up to 15 column places with column 57 being the maximum per row.
- A comma following the prompt text in an INPUT statement does not display a question mark. A semicolon or no prompt does.
- Commas are also used between INPUT statement variables when more than one input is required.
- LINE INPUT can use a comma or semicolon after the prompt text. Neither will display a question mark.
- Commas are used as argument separators in many kinds of Qbasic statements and SUB or FUNCTION parameter lists.
- WRITE statements use commas to separate values printed to the screen or sent to a file without tab spacing them.
- Literal numerical values entered into program code, DATA, files or user INPUT cannot contain comma separators!
Example 2: Comparing PRINT and WRITE statement displays.
23567 45678 354126 23567,45678,354126
- Note: WRITE does not space any values. The commas separate the numerical values without the normal PRINT spacing.