Thursday, July 30, 2020

How to use IF function in Microsoft excel?

How to use IF function in Microsoft excel?


 

About Function:

The IF function perform a logical test and returns different value for TRUE result and FALSE result.

The example is shown in above picture with formula to get a quick performance analysis of student. In that table the student who have received 50% above marks are marked as “Pass” and who have received less than 50% are “Fail”.

More than one condition can also be tested in IF function by using nesting IF functions. The IF function can be combined with logical functions like AND and OR to extend the logical test.

Purpose of the Function:

To perform specific condition

Output Value:

The value for TRUE or FALSE condition

Syntax:

=IF(logical_test, [value_if_true], [value_if_false])

Arguments:

logical_test – value or expression that can be evaluated.

value_if_true – [Optional] the value to return if logical test is TRUE

value_if_false - [Optional] the value to return if logical test is FALSE

Example:

The IF function will perform the logical test on a specific cell and react with the logical test is TRUE or FALSE. The IF function will return the respective value for TRUE or FALSE result.

In our example, we have table of marks of different student. We have performed IF function to get a quick performance result of students. The student who have more than 50% marks are “Pass” and who have less than 50% marks are “Fail”

 

=IF(D5>50, “Pass”, “Fail”)

returns Pass, if mark is more than 50 otherwise returns Fail

More example of possible logical test in the same example is also shown in below table:

=IF(D5>=50, “Pass”, “Fail”)
=IF(D5<=50, “Fail”, “Pass”)
=IF(D5<50, “Fail”, “Pass”)

Other Relevant Posts:



Previous Post
Next Post

0 comments:

Please do not enter any spam link in the comment box