Excel-IF Nested IF and IFS Practice Questions with Solutions

Introduction

The IF function is one of the most useful Excel functions for making decisions based on conditions. It can return different results depending on whether a condition is true or false. In this chapter, you will practice IF, Nested IF, and IFS with student results, employee performance, sales targets, discounts, grades, and other practical examples. The questions start with simple conditions and gradually move toward multiple-condition problems. Excel-IF Nested IF and IFS practice questions with solutions to help you understand the concepts.

Q1. Check Whether a Student Passed or Failed

Problem Statement

A student passes if their marks are 40 or more. Use IF to display "Pass" or "Fail".

Sample Data

StudentMarks
Rahul75
Priya38
Amit62
Neha29
Karan45

Excel Formula

In C2:

=IF(B2>=40,"Pass","Fail")

Copy the formula down.

Output

StudentMarksResult
Rahul75Pass
Priya38Fail
Amit62Pass
Neha29Fail
Karan45Pass

Explanation

The formula checks:

Marks >= 40

If the condition is true, Excel returns:

Pass

Otherwise:

Fail

Concept Covered

  • IF
  • Comparison operator
  • True/False result

Q2. Check Employee Bonus Eligibility

Problem Statement

An employee receives a bonus if their sales are ₹50,000 or more.

Sample Data

EmployeeSales
Rahul55000
Priya42000
Amit65000
Neha48000
Karan70000

Excel Formula

=IF(B2>=50000,"Bonus","No Bonus")

Output

EmployeeSalesBonus Status
Rahul55000Bonus
Priya42000No Bonus
Amit65000Bonus
Neha48000No Bonus
Karan70000Bonus

Explanation

Excel checks whether the sales value is at least ₹50,000.

For Rahul:

55000 >= 50000 → TRUE

Therefore:

Bonus

Concept Covered

  • IF
  • Numeric condition
  • Business decision

Q3. Categorize Students Using Nested IF

Problem Statement

Classify students according to their marks:

  • 80 or above → Excellent
  • 60 or above → Good
  • 40 or above → Pass
  • Below 40 → Fail

Sample Data

StudentMarks
Rahul92
Priya76
Amit58
Neha35
Karan64

Excel Formula

=IF(B2>=80,"Excellent",IF(B2>=60,"Good",IF(B2>=40,"Pass","Fail")))

Output

StudentMarksResult
Rahul92Excellent
Priya76Good
Amit58Pass
Neha35Fail
Karan64Good

Explanation

This is a Nested IF because one IF is placed inside another IF.

Excel checks the conditions in order:

Marks >= 80

If false:

Marks >= 60

If false:

Marks >= 40

If all are false:

Fail

Concept Covered

  • Nested IF
  • Multiple conditions
  • Student grading

Q4. Assign Grades Using Nested IF

Problem Statement

Assign grades according to percentage:

PercentageGrade
90 or aboveA+
80–89A
70–79B
60–69C
Below 60D

Sample Data

StudentPercentage
Rahul95
Priya84
Amit73
Neha65
Karan52

Excel Formula

=IF(B2>=90,"A+",IF(B2>=80,"A",IF(B2>=70,"B",IF(B2>=60,"C","D"))))

Output

StudentPercentageGrade
Rahul95A+
Priya84A
Amit73B
Neha65C
Karan52D

Explanation

Excel evaluates the conditions from left to right.

For Amit:

73 >= 90 → FALSE
73 >= 80 → FALSE
73 >= 70 → TRUE

Therefore:

B

Concept Covered

  • Nested IF
  • Grade classification
  • Multiple ranges

Q5. Categorize Sales Performance Using IFS

Problem Statement

Classify employees based on their monthly sales:

  • ₹70,000 or more → Excellent
  • ₹50,000 or more → Very Good
  • ₹30,000 or more → Good
  • Below ₹30,000 → Needs Improvement

Sample Data

EmployeeSales
Rahul85000
Priya62000
Amit45000
Neha25000
Karan73000

Excel Formula

=IFS(B2>=70000,"Excellent",B2>=50000,"Very Good",B2>=30000,"Good",B2<30000,"Needs Improvement")

Output

EmployeeSalesPerformance
Rahul85000Excellent
Priya62000Very Good
Amit45000Good
Neha25000Needs Improvement
Karan73000Excellent

Explanation

IFS allows you to test multiple conditions without repeatedly writing IF.

For Amit:

45000 >= 70000 → FALSE
45000 >= 50000 → FALSE
45000 >= 30000 → TRUE

Result:

Good

Concept Covered

  • IFS
  • Multiple conditions
  • Sales classification

Q6. Calculate a Discount Based on Purchase Amount

Problem Statement

Give customers a discount according to their purchase amount:

  • ₹50,000 or more → 20%
  • ₹30,000 or more → 15%
  • ₹10,000 or more → 10%
  • Below ₹10,000 → 5%

Sample Data

CustomerPurchase Amount
Rahul55000
Priya35000
Amit18000
Neha7000
Karan62000

Excel Formula

=IFS(B2>=50000,20%,B2>=30000,15%,B2>=10000,10%,B2<10000,5%)

Output

CustomerPurchase AmountDiscount
Rahul5500020%
Priya3500015%
Amit1800010%
Neha70005%
Karan6200020%

Explanation

For Priya:

35000 >= 50000 → FALSE
35000 >= 30000 → TRUE

Therefore, the discount is:

15%

Concept Covered

  • IFS
  • Percentage values
  • Conditional pricing

Q7. Calculate Employee Commission Using Nested IF

Problem Statement

Calculate commission based on sales:

  • ₹100,000 or more → 10%
  • ₹75,000 or more → 7%
  • ₹50,000 or more → 5%
  • Below ₹50,000 → 2%

Then calculate the actual commission amount.

Sample Data

EmployeeSales
Rahul120000
Priya85000
Amit60000
Neha42000
Karan100000

Commission Rate Formula

=IF(B2>=100000,10%,IF(B2>=75000,7%,IF(B2>=50000,5%,2%)))

Commission Amount Formula

If the commission rate is in C2:

=B2*C2

Output

EmployeeSalesRateCommission
Rahul12000010%12000
Priya850007%5950
Amit600005%3000
Neha420002%840
Karan10000010%10000

Explanation

For Priya:

85000 >= 100000 → FALSE
85000 >= 75000 → TRUE

So her commission rate is:

7%

Commission:

85000 × 7% = 5950

Concept Covered

  • Nested IF
  • Percentage calculation
  • Commission calculation
  • Business data analysis

Q8. Check Stock Status Using IF

Problem Statement

Display:

  • "Out of Stock" if stock is 0
  • "Low Stock" if stock is 1–10
  • "In Stock" if stock is greater than 10

Sample Data

ProductStock
Laptop15
Mouse0
Keyboard8
Monitor25
Webcam5

Excel Formula

=IF(B2=0,"Out of Stock",IF(B2<=10,"Low Stock","In Stock"))

Output

ProductStockStatus
Laptop15In Stock
Mouse0Out of Stock
Keyboard8Low Stock
Monitor25In Stock
Webcam5Low Stock

Explanation

The formula first checks whether stock is zero.

If not, it checks whether stock is 10 or less.

For Keyboard:

8 = 0 → FALSE
8 <= 10 → TRUE

Result:

Low Stock

Concept Covered

  • Nested IF
  • Inventory analysis
  • Multiple conditions

Q9. Check Eligibility Using IF and AND

Problem Statement

A student is eligible for a scholarship if:

  • Marks are at least 80
  • Attendance is at least 75%

Sample Data

StudentMarksAttendance
Rahul9085%
Priya8270%
Amit7590%
Neha8880%
Karan7985%

Excel Formula

=IF(AND(B2>=80,C2>=75%),"Eligible","Not Eligible")

Output

StudentMarksAttendanceResult
Rahul9085%Eligible
Priya8270%Not Eligible
Amit7590%Not Eligible
Neha8880%Eligible
Karan7985%Not Eligible

Explanation

AND requires both conditions to be true.

For Rahul:

Marks >= 80       → TRUE
Attendance >= 75% → TRUE

Therefore:

Eligible

For Priya:

Marks >= 80       → TRUE
Attendance >= 75% → FALSE

Therefore:

Not Eligible

Concept Covered

  • IF
  • AND
  • Multiple conditions
  • Eligibility checking

Q10. Compare Nested IF and IFS for Employee Performance

Problem Statement

Create an employee performance classification using four levels:

  • 90 or above → Outstanding
  • 75 or above → Excellent
  • 60 or above → Good
  • Below 60 → Needs Improvement

Solve the problem using both Nested IF and IFS.

Sample Data

EmployeePerformance Score
Rahul95
Priya82
Amit68
Neha55
Karan91

Solution 1: Nested IF

=IF(B2>=90,"Outstanding",IF(B2>=75,"Excellent",IF(B2>=60,"Good","Needs Improvement")))

Solution 2: IFS

=IFS(B2>=90,"Outstanding",B2>=75,"Excellent",B2>=60,"Good",B2<60,"Needs Improvement")

Output

EmployeeScoreResult
Rahul95Outstanding
Priya82Excellent
Amit68Good
Neha55Needs Improvement
Karan91Outstanding

Explanation

Both formulas produce the same result.

The difference is mainly in how the conditions are written.

Nested IF:

IF
 └── IF
      └── IF

IFS:

Condition 1 → Result 1
Condition 2 → Result 2
Condition 3 → Result 3
Condition 4 → Result 4

For several conditions, IFS can make the formula easier to read.

Concepts Covered

  • Nested IF
  • IFS
  • Multiple conditions
  • Performance classification
  • Comparing Excel functions

Key Takeaways

  • IF is used to make decisions based on a condition.
  • Nested IF allows you to test multiple conditions.
  • IFS provides a convenient way to handle multiple conditions.
  • AND can be combined with IF when all conditions must be true.
  • The order of conditions is important in Nested IF and IFS.
  • Higher thresholds should generally be checked before lower thresholds when creating categories.
  • IF can be used for grades, bonuses, discounts, stock status, eligibility, and many other practical tasks.
  • IFS can make formulas with many conditions easier to read.
  • Nested IF remains useful for compatibility and situations where IFS is not available.
  • Practice with real datasets helps you understand when to use each conditional function.

FAQs

1. What is the IF function in Excel?

IF checks whether a condition is true or false and returns one result when true and another result when false.

Example:

=IF(B2>=40,"Pass","Fail")

2. What is a Nested IF formula?

A Nested IF is an IF formula containing another IF function. It is used when more than two possible results are required.

Example:

=IF(B2>=80,"A",IF(B2>=60,"B",IF(B2>=40,"C","F")))

3. What is the IFS function in Excel?

IFS checks multiple conditions and returns the result associated with the first condition that evaluates to TRUE.

Example:

=IFS(B2>=80,"A",B2>=60,"B",B2>=40,"C",B2<40,"F")

4. What is the difference between IF and IFS in Excel?

IF is generally used for a condition with two possible outcomes, while IFS is designed to handle multiple conditions and corresponding results.

5. Is IFS better than Nested IF?

They solve similar types of problems, but IFS can make formulas with many conditions easier to read. Nested IF can still be useful when working with older Excel versions or when a specific formula structure is needed.

6. Can IF be combined with AND?

Yes. IF and AND can be combined when multiple conditions must be true.

=IF(AND(B2>=80,C2>=75%),"Eligible","Not Eligible")

7. Does the order of conditions matter in IFS?

Yes. IFS returns the result for the first TRUE condition. Therefore, conditions should be arranged carefully.

Written by Shubhranshu Shekhar, who has trained 20000+ students in coding.

Scroll to Top