And operatorAnd Operator (&)

Used to combine two conditions. Both conditions must be found true in order for the expression to be true.

Syntax

condition1&condition2

Example 1

C1000>=0&C100>=0

where C1000 = 500 and C100 = 600.

Both conditions are true and therefore the expression is true.

Example 2

The above example can be used in conjunction with the Case function to determine if a cell displays "Net Income" or "Net Loss".

CASE(C1000>=0&C100>=0,"Net Income",C1000<0&C100<0,"Net Loss")

The preceding calculation may be evaluated as follows:

If both the current and prior year Net Income (loss) accounts have values that are greater than or equal to zero, then display, "Net Income". If both the current and prior year Net Income (loss) accounts have values that are less than zero, then display, "Net Loss".

In the case where C1000 = 500 and C100 = 600, the cell will display "Net Income".

Related Topics