Skip to content

IF with AND / OR

Return one result when several conditions are all true (AND) or when any is true (OR).

The formula

Argument separator
Excel and Google Sheets
=IF(AND(B2>=50, C2="Yes"), "Pass", "Fail")

How it works

  1. AND(B2>=50, C2="Yes")

    True only when the score is at least 50 and attendance is Yes. Swap AND for OR to need just one.

  2. "Pass", "Fail"

    What to show when the test is true, and when it is false.

Example

B: ScoreC: AttendedD: Result
72YesPass
72NoFail
41YesFail

Tips

  • Text comparisons are not case-sensitive: "yes" equals "Yes".