and, &

Find logical AND

Syntax and Description

A & B performs a logical AND of arrays A and B and returns an array containing elements set to either logical 1 (true) or logical 0 (false). An element of the output array is set to logical 1 (true) if both A and B contain a nonzero element at that same array location. Otherwise, the array element is set to 0.
and(A,B) is an alternate way to execute A & B, but is rarely used.

Back to functions