Вы находитесь на странице: 1из 6

Using the

Function in Excel
What is an IF statement

A calculation that uses IF-THEN-ELSE logic.

Example:
"If all philosophers are thinkers and John is
a philosopher, then John is a thinker."
Parts of the IF functions
Cell
Equal Sign
Reference

=IF(B2=“Answer","Correct","Wrong")
Function Name Truth Value value if True value if False

Operator: Can be
= , < , >, >=, <=, Notice, Values are
separated by commas.
Example of If statement in Excel

Function
A B C
The planets revolve around this. Sun =IF(B1="sun","Correct","Wrong")

Output
A B C
The planets revolve around this. Sun Correct
Write the correct IF Statement

A B C
What is the President’s last name

A B C
What is the President’s last name =if
A B C
What is the President’s last name =if(b1=

A B C
What is the President’s last name =if(b1=“Obama”,
A B C
What is the President’s last name =if(b1=“Obama”, “Correct”,
A B C
What is the President’s last name =if(b1=“Obama”, “Correct”, “Incorrect”)
Write the correct IF Statement
Write an if statement that outputs “True” if B1 is Greater than A1

A B C
23 35

A B C
23 35 =if
A B C
23 35 =if(b1>

A B C
23 35 =if(b1>a1,
A B C
23 35 =if(b1>a1,True,
A B C
23 35 =if(b1>a1,True,False)

Вам также может понравиться