Operators & Math

PooLang supports standard arithmetic operations with proper mathematical precedence (PEMDAS).

Arithmetic Operators

OperatorDescriptionExample
+Addition5 + 2
-Subtraction10 - 4
*Multiplication3 * 3
/Division20 / 5

Precedence Example

poo result << 10 + 5 * 2; # result is 20 (5*2=10, 10+10=20)

Comparison Operators

These operators return a Boolean (true or false).

OperatorDescription
==Equal to
!=Not equal to
>Greater than
<Less than
>=Greater than or equal to
<=Less than or equal to

Logical Operators

OperatorDescription
&&Logical AND
`
!Logical NOT