Operators

<< Click to Display Table of Contents >>

Home  mIoTa BASIC > mIoTa BASIC Language Reference > Lexical Elements > Tokens >

Operators

Operators are tokens that trigger some kind of computation when being applied to variables and other objects in an expression.

 

There are four types of operators in mIoTa BASIC:

 

Arithmetic Operators

 

Bitwise / Boolean Operators

 

Relational Operators

 

 

Operator Precedence and Associativity

There are 4 precedence categories in mIoTa BASIC. Operators in the same category have equal precedence with each other.

 

Each category has an associativity rule: left-to-right, or right-to-left. In the absence of parentheses, these rules resolve the grouping of expressions with operators of equal precedence.

 

Precedence

Operators

No. of Operands

Associativity

4

not  - (negate)

1

right-to-left

3

*  /  mod  and  shl  shr

2

left-to-right

2

+  -  or  xor

2

left-to-right

1

=  <>  <  >  <=  >=

2

left-to-right