Page History
...
Arithmetic Operators | Description | Example |
---|---|---|
+ | Addition | 2 + 1 |
- | Subtraction | 2 - 1 |
* | Multiplication | 3 * 2 |
: | Division | 6 / : 2 |
Unary Operator | Description | Example |
---|---|---|
+ | Indicate a positive number | +2 |
- | Negate a number | -2 |
++ | Increment | x++ |
-- | Decrement | x-- |
Boolean Operator | Description | Example | |||
---|---|---|---|---|---|
== | Equal to | x == 2 | |||
! | Negate a boolean value | ! (x == 2) | == | Equal to | x == 2 |
!= | Not equal to | x != 2 | |||
> | Greater than | x > 2 | |||
>= | Greather than or equal to | x >= 2 | |||
< | Less than | x < 2 | |||
<= | Less than or equal to | x <= 2 | |||
&& | Conditional-AND | x > 0 && x < 9 | |||
|| | Conditional-OR | x < 0 || x > 9 |
Overview
Content Tools