Video
Syntax
=IF (logical_test, [value_if_true], [value_if_false])
logical_test – Checks a value or logical expression as TRUE or FALSE.
value_if_true – [optional] The value to return when logical_test is TRUE.
value_if_false – [optional] The value to return when logical_test is FALSE.
About IF Function
IF function performs a logical test and returns one value for a TRUE or FALSE result. For example, to “pass” scores must be above 35, So the construction of the formula reads as below
=IF(A1>35,"Pass","Fail")
If we just enter the logical test in IF function without declaring the value of TRUE it will return zero and FALSE then the cell will only return the result FALSE
=IF(A1>35,)
Also, we can test more than one condition by nesting IF functions which can be combined with logical functions like AND and OR. You must know the basic understanding of how logical operators works. Check out this Youtube Vidoe explaining in details about Logical Operators
Objective
Dose logical comparisons and return the result based on the logical tests.
Example 01 – with numbers
For example number one we will evaluate and display the results in each cell as “PASS”/ “FAIL” as per the logical test. Our logical test is students score greater than thirty-five.
=IF(A1>35,"Pass","Fail")
Example 02 – with text
In example number two we will evaluate and display the results in each cell as “YES” when the logical test is TRUE and FALSE we will return nothing. Our logical test is student’s country must be “INDIA”.
=IF(C5="India","Yes","")
Important Note: Whenever we are entering text make sure that they are inside double quote
Was the information helpful in this blog?
- If yes, hit that share button and show the excitement to the world.
- Subscribe to our free posts.
If no, please let us know what to improve.