
228
____________________________________________________________________
LINE INPUT
LINE INPUT
Reads input from the keyboard into a string variable.
____________________________________________________________________
Syntax:
Syntax:Syntax:
Syntax:
LINE INPUT ["prompt"{,|;}]stringvariable
Parameter:
Parameter:Parameter:
Parameter:
"prompt"
A string constant.
stringvariable
A string variable.
Description:
Description:Description:
Description:
When execution reaches a LINE INPUT statement, the program pauses and waits for the
user to enter data from the keyboard while showing a prompting message specified by
"prompt".
After typing data, the user must press the ENT key. Then, the LINE INPUT statement
assigns the typed data to stringvariable.
• A LINE INPUT statement cannot assign a numeric variable. (An INPUT statement can
do.)
• "prompt" is a prompting message to be displayed on the LCD.
• The semicolon (;) or comma (,) after "prompt" has the following meaning:
If "prompt" is followed by a semicolon, the LINE INPUT statement displays the
prompting message followed by a question mark and a space.
LINE INPUT "data=";a$
data=?
Comentarios a estos manuales