Cellgrids Cellgrids
Home › Practice questions › IFERROR › Question 5

Excel IFERROR Practice Question: Find the average of the three marks in B to D for each student. Show No marks…

By Rinkesh Shah, founder of Cellgrids.

The question

Find the average of the three marks in B to D for each student. Show No marks when the row is empty. Put it in E2 to E4.

The data

ABCDE
1NameT1T2T3Average
2Rahul607080?
3Priya?
4Amit5070?

The yellow cells are where your answer goes.

Show answer

Expected results:

  • E2 = 70
  • E3 = No marks
  • E4 = 60

How it works

Explanation: AVERAGE of empty cells gives #DIV/0!. IFERROR shows a message instead. Empty cells inside a row are ignored.
Syntax: =IFERROR(AVERAGE(B2:D2),"No marks")
Rahul averages 70. Priya has no marks, so No marks. Amit has 50 and 70, so the average is 60.

Try it yourself in the live sheet

Type your formula in the highlighted cell and get instant feedback. Free, no Excel install needed.

Try this question in the live sheet →

IFERROR syntax

=IFERROR(value, value_if_error)

Runs a formula, but shows a fallback value instead of an error if it fails. IFERROR is used to build decision rules directly into a spreadsheet instead of manually judging each row. Full IFERROR guide.

More IFERROR practice questions

All practice questions · Excel exercises · Interview prep · Cheat sheet