The keyword and is the logical AND operator in Envision.
(boolean and boolean) -> boolean, const autodiff operator
When found in an expression, and is the logical AND operator.
table T = with
[| as A, as B |]
[| false, false |]
[| false, true |]
[| true, false |]
[| true, true |]
show table "" with
T.A
T.B
T.A and T.B
The code above outputs the following table:
A
B
(T.A and T.B)
False
False
False
False
True
False
True
False
False
True
True
True
Advanced remark: If one of the expressions evaluates to false, it is unspecified whether the other expression will be evaluated or not. For example, the following code might or might not raise a division-by-zero warning, but will always print false:
a = 10
b = 0
// false
show scalar "Test" with b > 0 and a / b > 0