Excel’s true usage is making data analysis faster, easier, and efficient. Let’s say a teacher teaches a class of 50. In the finals, he has to check 50 copies and make a grade sheet.
This task is tedious, stressful, and time consuming.
But excel is here to make the teacher’s life a little easier. After checking the copies, he can input the marks in excel and a one-line formula can create results for the 50 students instantly.
The one-line formula is known as an IF formula. It is one of the most popular formulas in excel and excel enthusiasts use this formula for various purposes.
So, let’s see how to use IF formula in excel.
What is the IF Formula?
IF is a conditional function and it checks whether a certain condition is true or not. Based on the condition’s being true or false, it can generate a statement or result as per your wish.
Before we use the IF function in excel, let’s break down its arguments to better understand the formula.
IF Function’s Arguments
The syntax of the formula looks like this:
We can see that the IF formula has three arguments.
01# logical_test: This is the condition to be tested. For example- you can test whether a number is greater or smaller than any other number(s), you can test whether a product has been sold or not, you can test whether a product belongs to a certain price range or not, and many more.
The condition can be specified using various logical operators that include- = (equal to), > (greater than), >= (greater than or equal to), < (less than), <= (less than or equal to), <> (not equal to).
02# value_if_true: This is an optional argument. After you specify your condition and if the condition is true it will return “TRUE.”
03# value_if_false: This is an optional argument. After you specify your condition and if the condition is false it will return “False.”
Now, let’s dive into how to use IF formula in excel.
How to Use if Formula in Excel?
There are various ways you can use an IF formula. I will show you three ways. Simple, Nested, and with AND/OR.
Method 1# Simple use of IF formula in excel
The teacher wants to declare if a student has passed or failed in the result column.
A student fails if he/she scores 49 or lower. This is our condition.
So, the formula is:
After typing the formula, drag the fill handle down to reveal all the results.
You can see that four students have failed and all of them scored below 49.
Method 2# Use of Nested IF formula in excel
Nested IF simply means using two or more Ifs in a single formula. To know the grade of the students the teacher can use nested IF in excel.
The teacher has decided the following grading criteria:
Now, he needs to write the formula. The formula will be:
After typing the formula, drag the fill handle down to reveal all the grades.
Method 3# Use of OR with IF in excel
The teacher has decided that if a student gets a B or above then he/she will get a prize.
So, to know who gets a prize the formula to enter is
There you have it. The use of IF formula is very versatile and can be used on numerous occasions. Now, you also know how to use IF formula in excel.
Hi there, I am Naimuz Saadat. I am an undergrad studying finance and banking. My academic and professional aspects have led me to revere Microsoft Excel. So, I am here to create a community that respects and loves Microsoft Excel. the community will be fun, helpful and respectful that nurtures individuals into great excel enthusiasts.