C5 Operators

String : 

+ : Concatenate
- : Concatenate without intervening spaces

Mathematical : 

+ : Addition or Unary Positive
- : Subtraction or Unary Negative
* : Multiplication
/ : Division
% : Modulus--binary 
** or ^ : Exponentiation

Relational : 

<      : Less than
>      : Greater than
=     : Equal
==  : Exactly equal for character; equal for other data types
<>, #, or !=  : Not equal
<=   :  Less than or equal
>=   : Greater than or equal
$     : Is contained in the set or is a subset of  (Substring comparison)

Logical : 

.AND. : Logical and
.OR.  : Logical or
.NOT. or ! : Logical negate

Assignment :

=  : Assign
:= : Inline assign
+= : Inline add (or concatenate) and assign
-= : Inline subtract (or concatenate) and assign
*= : Inline multiply and assign
/= : Inline divide and assign
^= : Inline exponentiate and assign
%= : Inline modulus and assign

Increment and Decrement :

++ : Prefix or postfix increment
-- : Prefix or postfix decrement

Special : 

:: : Send a message to an object
() : Function or grouping
[] : Array element
{} : Constant array definition
-> : Alias identifier
&  : Compile and execute (Macro evaluation--unary)
@  : Pass by reference

Leave a comment

This site uses Akismet to reduce spam. Learn how your comment data is processed.