Omron C200H-ASC11 Manual page 177

Ascii units
Hide thumbs Also See for C200H-ASC11:
Table of Contents

Advertisement

Details of BASIC Commands
let
Syntax:
[
LET
Statement. Assigns a value of the <expression> on the right hand side of the statement to the
Description:
variable on the left-hand side of the expression.
Remarks:
The keyword
for assignment.
Assigning character expressions to numeric variables and vice-versa result in a "TYPE
MISMATCH" error (code B013).
If the numerical expression on the right hand side of the assignment is a different type to the
variable on the left hand side then the expression on the right hand side is converted to the type
of the variable on the left hand side before assignment.
> 10 LET A = 12.34
Examples:
> 20 PRINT A
> RUN
12.34
>
See also:
line input
Syntax:
LINE INPUT
Statement. Inputs an entire line of characters from the keyboard, or some other input device,
Description:
without delimiters.
<port expression> is an expression returning an integer in the range: [1... 3].
Remarks:
If the <port expression> is omitted the default terminal port is assumed.
<prompt> is an optional text string that is output to the terminal to prompt for the input. If the port
specified is not configured as a "TERM" or a "COMU" port then the prompt will be suppressed.
Unlike the
All input will be assigned to the character variable until a carriage return is entered. The
maximum length of the character string is 255 characters. while waiting for input the BASIC LED
will be blinking.
Commas and colons are treated as part of the input string.
Note:
> 10 OPEN #1, "TERM:"
Examples
> 20 LINE INPUT #1, "ENTER YOUR FULL NAME : "; A$
> 30 PRINT "HELLO ";A$
> 40 END
> RUN
ENTER YOUR FULL NAME : JOE BLOGGS<CR>
HELLO JOE BLOGGS
>
See also:
INPUT
168
] <variable> = <expression>
is optional in the assignment statement. It is sufficient to use the "=" character
LET
[;][# <port expression>,][<"prompt"> (;|,)]<character variable>
statement the '?' is only possible by including it in the prompt.
INPUT
If a semi-colon is added after the LINE INPUT, the cursor will remain on the same row
after input.
7-6
Section

Advertisement

Table of Contents
loading

This manual is also suitable for:

C200h-asc21C200h-asc31

Table of Contents