4.1 GENERAL COMMANDS
This section describes commands that are not confined to any specific hardware features.
ABS
Purpose
To return the absolute value of a numeric expression.
Syntax
A = ABS(N)
"A" is a numeric variable to be assigned to the absolute value of a numeric
expression.
"N" is a numeric expression; it can be an integer or a real number.
Example
TimeDifference% = ABS(Time1% - Time2%)
BIT_OPERATOR
Purpose
To perform bit-wise operations of integers or long integers.
Syntax
C = BIT_OPERATOR(operator%, A, B)
Remarks
"C" is an integer (C%) or long integer variable (C&) to be assigned to the
result.
"operator%" is an integer variable, indicating the bit-wise operator. (see below)
"A" is an integer (A%) or long integer (A&) variable, indicating the 1
"B" is an integer (B%) or long integer (B&) variable, indicating the 2
Example
Result& = BIT_OPERATOR(2, 1100, 1000)
DIM
Purpose
To specify the maximum value of variable subscripts and to allocate storage
accordingly.
Syntax
DIM Array (range {,range}) {, Array(range {,range})}
Remarks
"Array" is an array variable.
"range" can be an integer or an integer expression.
The DIM statement sets all the elements of the specified arrays to an initial
value of zero or empty string.
Note that the maximum allowable number of dimensions for an array is 2.
Example
DIM A(10), B%(20), C$(30, 10)
OPERATOR%
Meaning
1
bit-wise AND
2
bit-wise OR
3
bit-wise XOR
Chapter 4
BASIC Commands
st
nd
operand.
operand.
29
Need help?
Do you have a question about the 8 Series and is the answer not in the manual?