Free demo · Google Sheets · Lesson 5 · Intermediate · IF function
The IF function: let the sheet decide
IF asks a yes-or-no question and gives one answer when it is true and another when it is false. Here: who has paid the full camp fee?
- 1The question: is Paid at least the Fee?
- 2Type
=IF(C2>=B2,"Paid","Due") - 3Enter: 1500 ≥ 1500 is TRUE, so Asha is Paid
- 4Fill down: every row tests its own numbers
- 5Kabir pays the rest: Due becomes Paid by itself
- ✓Text in quotes, numbers without:
=IF(C2>=B2,0,B2-C2)gives the balance