3.1 General-Purpose Libraries
3.1.1 Global Utilities
3.1.2 Numbers
3.1.3 Strings
3.1.4 Booleans
3.1.5 option
3.1.6 either
3.1.7 pick
3.1.8 lists
3.1.9 sets
3.1.10 arrays
3.1.11 string-dict
3.1.12 Tables
3.1.13 gdrive-sheets
3.1.14 csv
3.1.15 color
3.1.16 The image libraries
3.1.17 reactors
3.1.18 chart
3.1.19 plot
3.1.20 statistics
3.1.21 math
3.1.22 matrices
3.1.23 Timing
3.1.24 fetch
3.1.25 filesystem
On this page:
Boolean
3.1.4.1 Boolean Functions
not
3.1.4.2 Boolean Operators
and
or
3.1.4 Booleans🔗

The type of the values true and false.

3.1.4.1 Boolean Functions🔗

not :: (b :: Boolean) -> Boolean

Returns true when given false and vice versa.

Examples:

check: not(true) is false not(2 < 1) is true end

3.1.4.2 Boolean Operators🔗

The and operator “short-circuits”: if left evaluates to false, then right is not evaluated at all and the result is false.

Expects left and right to be Booleans. If both are true, the result is true, if either is false, the result is false.

Examples:

examples: true and true is true true and false is false false and true is false false and false is false (4 < 5) and ("a" == "b") is false (4 < 5) and ((4 + 2) == 6) is true (4 > 5) and ((4 + 2) == 6) is false end

The or operator “short-circuits”: if left evaluates to true, then right is not evaluated at all and the result is true.

Expects left and right to be Booleans. If either is true, the result is true, if both are false, the result is false.

Examples:

examples: true or true is true true or false is true false or true is true false or false is false (4 < 5) or ("a" == "b") is true (4 < 5) or ((4 + 2) == 6) is true (4 > 5) or ((4 + 2) == 6) is true (4 > 5) or ("a" == "b") is false end