and

Help Contents Arithmetic Logical Operations and
Logical Operations or

and tf1 tf2
(and tf1 tf2 tf3 ...)


outputs TRUE if all inputs are TRUE, otherwise FALSE. All inputs must be TRUE or FALSE. (Comparison is case-insensitive regardless of the value of CaseIgnoredP. That is, "true" or "True" or "TRUE" are all the same.)

If some of the inputs are lists instead of boolean values, the get evaluated from left to right, but on the first FALSE argument AND will stop the evaluation. With this it is possible to avoid many nested ifElse clauses neccessarily used in earlier versions of aUCBLogo.

Examples:

and true false		;false  ;-)
and true true		;true  ;-)
and false true		;false  ;-)
and false false		;false  ;-)
(and true true true)		;true  ;-)
(and true true false)		;false  ;-)

show and 3 < 4 [pr 5 1 < 2]	
;5
;true
show and 3==4 [pr 5 1 < 2]
;false

See also:

Examples:

References:

Logical Operations or