OTX Divide
From emotive
Contents
Classification
Name | Divide |
Short Description | Returns the quotient of two operands |
Class | Term |
Extension | OTX Core library |
Group | Operations |
Exceptions | - |
Checker Rules | - |
Standard Compliant | Yes |
OTL Syntax
NumericValue = NumericTerm1 / NumericTerm2;
Description
Divide is a NumericTerm which returns the quotient of two operands. The following operator can be used: /
Return Value
The Term returns the value, see table below.
In OTX, Terms are categorized according to its return data type!
Data Type | Description |
Integer, Float | The quotient of two operands. If one or more operands is of type float, the return value is float. Otherwise, the return value of the type is integer. |
Properties
Name | Data Type | Class | Default | Cardinality | Description |
Numeral | Integer, Float | Term | - | [1] | A numeric term which represents the dividend value |
Divisor | Integer, Float | Term | - | [1] | A numeric term which represents the divisor value |
OTL Examples
/// Local Declarations
Integer MyValue1 = 1;
Integer MyValue2 = 5;
Integer Result1;
Float Result2;
/// Flow
Result2 = MyValue1 / 115;
Result2 = MyValue1 / 1.5;
Integer MyValue1 = 1;
Integer MyValue2 = 5;
Integer Result1;
Float Result2;
/// Flow
Result2 = MyValue1 / 115;
Result2 = MyValue1 / 1.5;
See also
Add
Subtract
Multiply
Quantities Division
Modulo
AbsoluteValue
Round
Negate