Google Sheets Function: AND

The AND function checks each test and returns TRUE only if all tests are TRUE and FALSE otherwise.

This function is generally used in combination with other functions (notably the IF function).

Usage:

=AND(logical_expression1, logical_expression2, ...)


Using the function alone

The objective here is to check if the member is enrolled in both course A and course F.

The tests B2="A" and C2="F" are therefore entered as arguments in the AND function:

=AND(B2="A",C2="F")
google sheets function and

Using with another function

The AND function can only return TRUE or FALSE, which is why it is most often used with other functions.

To display "Yes" or "No" instead of TRUE and FALSE, nest this function in an IF.

The formula then becomes:

=IF(AND(B2="A",C2="F"),"Yes","No")
google sheets functions and if
If needed, you can copy the Google Sheets document (or view the document) with this example.