Scripting:Operators

From STNE Wiki

(Difference between revisions)
Jump to: navigation, search
Line 1: Line 1:
{| cellpadding="3"
{| cellpadding="3"
-
! Operator !! Usage !! Returns
+
! Operator !! Syntax
|-
|-
-
| colspan="3" | String operators
+
| colspan="3" style="font-style:italic;" | String operators
|-
|-
-
| & || String1 & String2 || the concatenatenation of String1 and String 2
+
| Concatenation || a & b
|-
|-
-
| colspan="3" | Arithmetic operators
+
| colspan="3" style="font-style:italic;" | Comparison operators
|-
|-
-
| + || Number1 + Number2 || Number1 added to Number2
+
| Equal to      || a = b
|-
|-
-
| - || Number1 - Number2 || Number2 subtracted from Number1
+
| Not equal to  || a = b
|-
|-
-
| * || Number1 * Number2 || Number1 multiplied by Number2
+
| Greather than  || a > b
|-
|-
-
| / || Number1 / Number2 || Number1 divided by Number2
+
| Less than      || a < b
|-
|-
-
| colspan="3" | Logical operators
+
| Greather than or equal to || a >= b
|-
|-
-
| NOT || NOT Boolean1          || the logical inverse of the expression Boolean1
+
| Less than or equal to    || a <= b
|-
|-
-
| AND || Boolean1 AND Boolean2 || the logical AND of Boolean1 and Boolean2
+
| Reference equal to        || a Is b
|-
|-
-
| OR  || Boolean1 OR Boolean2  || the logical OR of Boolean1 and Boolean2
+
| colspan="3" style="font-style:italic;" | Arithmetic operators
 +
|-
 +
| Addition      || a + b
 +
|-
 +
| Subtraction    || a - b
 +
|-
 +
| Multiplication || a * b
 +
|-
 +
| Division      || a / b
 +
|-
 +
| colspan="3" style="font-style:italic;" | Logical operators
 +
|-
 +
| Logical NOT    || NOT a
 +
|-
 +
| Logical AND    || a AND b
 +
|-
 +
| Logical OR     || a OR b
 +
 
|}
|}

Revision as of 15:35, 10 September 2010

Operator Syntax
String operators
Concatenation a & b
Comparison operators
Equal to a = b
Not equal to a = b
Greather than a > b
Less than a < b
Greather than or equal to a >= b
Less than or equal to a <= b
Reference equal to a Is b
Arithmetic operators
Addition a + b
Subtraction a - b
Multiplication a * b
Division a / b
Logical operators
Logical NOT NOT a
Logical AND a AND b
Logical OR a OR b
Personal tools