IF: making a decision

1 / 5

IF shows one thing or another, depending on a yes-or-no question.

keyboard Typing formulas is easiest on a computer with a keyboard.

A1
ABCD
1NameScoreResult
2Tariq71
3Nadia59
4Daniel50
5Quinn74
6Jamal42
7Isla43
8
9
10
11
12
Pass or Fail
Type to enter a value or a formula starting with =. F2 edits, F4 adds $ to a reference.
Study notes

How IF works

  • What does IF do?

    IF shows one thing or another, depending on a yes-or-no question:

    =IF(question, if TRUE, if FALSE)

  • What are its three parts?

    • The question is a comparison, like B2>=50.
    • The second part is what to show when the answer is TRUE.
    • The third part is what to show when it's FALSE.
  • When do you need quotes?

    Text goes in double quotes: =IF(B2>=50,"Pass","Fail"). Numbers don't need quotes: =IF(B2>=50,10,0).

Know someone fighting with a spreadsheet? Send them this page.