KEYWORD OPERATIONS

Some of the keywords operations are:

The REM Statement: It consist of a statement number followed by the keyword REM and a textual message. It can be achieved using a single quotation mark. Example: 10 REM program to check for user’s password.

INPUT Statement: This is used to read data into the computer while the program is running. The data is obtained from the user through the keyboard. Example: INPUT A, INPUT B, INPUT C etc.

READ and DATA Statement: They are INPUT Statement. They are used to provide data to a computer in such a way that the program of the computer reads them as they are needed. The storage of data is done by the DATA Statement.

The READ statement is used when the input have been stored in the computer memory. That is why the READ and DATA statement is usually used together. The READ statements assign variables to DATA statement on a one-to-one basis.

Example, in the small program illustration below, the DATA are READ to Rate, Amount, and CustName.

DATA 7.5, 4700.00, “Uwa Edidiong

READ Rate, Amount, CustName

The DATA statements are supplied direct to the read values.

PRINT Statement: It is used to print output data on the screen. It consists of a statement number, keyword print and a list of variable to be worked on. Generally, the print statement has the form:

PRINT expression list [ ; I, ]
Where expression list is a list of one or more numeric or string expressions (variables and/or constants) to print to the screen.

The END Statement: Every program must have an end. This is marked by introducing an END statement. It indicates the terminating print of a program.

Leave a Comment

not allowed!