Toshiba KB-80 Computer Keyboard User Manual


 
- 22 -
DATA
Function Sets a numeric value or a character constant read by the READ statement.
Format DATA <constant> [, <constant> ] ···
Term <constant>: A numeric constant or character constant
Explanation The DATA statement is a non-executing statement, and should be placed before a
READ statement. The data which can be included in one line (max. 255 characters)
can be written in one DATA statement. There is no limit to the number of DATA
statements that can be used in one program.
The contents written in the DATA statement are interpreted as the data list to be
input. The data to be input is read by the READ statement in the ascending order of
the line number.
A numeric constant or character constant can be written in <constant>. Any of the
integer fixed-point, floating-point, octal notation, and hexadecimal notation can be
used for a numeric constant. Double quotation marks (”) enclosing a character
constant in the DATA statement can be omitted. However, they cannot be omitted
when a comma (,), colon (:), or semicolon (;) are included in the character string, and
when a space is entered in the beginning or end of the character string.
Note that the variable type should match the data type when the data in the DATA
statement is read by the READ statement. If there are any data types which do not
match, a “Syntax error” occurs.
Comments can not be attached to the line of the DATA statement.