Table of Contents

xor

Description

The boolean 'xor' function returns true if one, and only one, of its two boolean arguments are true.

Function prototype

bool xor <bool:arg1> <bool:arg2>

Arguments

Name Type Comment
arg1 bool The first boolean value.
arg2 bool The second boolean value.

Return value

True if:

False otherwise.

Example

echo <zs:xor false false> // should be false
echo <zs:xor false true> // should be true
echo <zs:xor true false> // should be true
echo <zs:xor true true> // should be false

… the output of which is written to the event log by echo as:

false
true
true
false

Comments

None.

See also