Power); (Is Equal To); (Assignment); (Is Not Equal To) - Omron TJ1-MC04 - PROGRAMMING 1 Programming Manual

Hide thumbs Also See for TJ1-MC04 - PROGRAMMING 1:
Table of Contents

Advertisement

BASIC commands
3.2.5

^ (Power)

/i
Type
Mathematical function
Syntax
expression_1 ^ expression_2
Description
The power operator ^ raises expression_1 to the power of expression_2.
This operation uses floating point algorithms and may give small deviations for
integer calculations.
Arguments
expression_1
A BASIC expression.
expression_2
A BASIC expression.
Example
result = 2^5
This assigns the value 32 to variable result.
See also
N/A
3.2.6

= (Is equal to)

/i
Type
Mathematical function
Syntax
expression1 = expression2
Description
The operator = returns TRUE if expression1 is equal to expression2, other-
wise it returns FALSE.
Arguments
expression1
Any valid BASIC expression.
expression2
Any valid BASIC expression.
Example
IF a = 10 THEN GOTO label1
If variable a contains a value equal to 10, program execution continues at
label label1. Otherwise, program execution continues with the next statement.
See also
N/A
PROGRAMMING MANUAL
3.2.7

= (Assignment)

/i
Type
Mathematical function
Syntax
variable = expression
Description
The operator = assigns the value of the expression to the variable.
Arguments
variable
A variable name.
expression
Any valid BASIC expression.
Example
var = 18
Assigns the value 18 to variable var.
See also
N/A
3.2.8
<> (Is not equal to)
/i
Type
Mathematical function
Syntax
expression1 <> expression2
Description
The operator <> returns TRUE if expression1 is not equal to expression2,
otherwise it returns FALSE.
Arguments
expression1
Any valid BASIC expression.
expression2
Any valid BASIC expression.
Example
IF a <> 10 THEN GOTO label1
If variable a contains a value not equal to 10, program execution continues at
label label1. Otherwise, program execution continues with the next state-
ment.
See also
N/A
42

Hide quick links:

Advertisement

Table of Contents
loading

This manual is also suitable for:

Tj1-mc16 - programming 1Tj1-mc04 1

Table of Contents