Intermediate · Lesson 5 of 12
Making decisions with IF
The three parts of IF
IF needs a test, what to show if it is true, and what to show if it is false. Text goes in quotation marks.
=IF(B2>=60,"Pass","Fail")Testing more than one thing
AND needs every test to pass. OR needs at least one. Put them inside IF as the test.
=IF(AND(B2>=40,C2="A"),"Bonus","None")More than two results
IFS checks tests in order and stops at the first true one. Start with the highest cutoff, and end with TRUE to catch everything else.
=IFS(B2>=90,"A",B2>=80,"B",TRUE,"C")