Or Else Operator

Returns “true” if one or more Boolean expressions are true, but stops after the first true expression.

Syntax

expression_1 Or Else expression_2

Parts

expression_1
A Boolean expression.
expression_2
A Boolean expression.

Instructions

The result has the type Boolean.

Or Else is almost the same as the operator Or. They are different when expression_1 is true. When this occurs, expression_2 is not calculated. This is correct because if one expression is true, then the result is always true. This is known as short-circuit evaluation.

Truth table for expression_1 Or Else expression_2
If expression_1 isAnd expression_2 isThe result is
Truenot calculatedTrue
FalseTrueTrue
FalseFalseFalse

Examples

TODO2

See also