The book: files and exercises · Lesson 13 of 24

Lesson 13 exercises: error values and IFERROR

Four exercises on error values with the Trip sheet in lesson13.xlsx: recognize #VALUE!, #DIV/0!, #NAME?, #N/A, #REF! and #####, understand the cause and replace an error with a message using IFERROR.

Lesson 13. Understanding and fixing error values

Use the Trip sheet in lesson13.xlsx: the cost per person of a year-end trip. It contains six different errors.

Files: lesson13.xlsx · solutions: lesson13-solutions.xlsx.

In the exercises with a sheet, type the formula in the fx bar and click Check: the sheet works it out the way Excel does, with commas between the arguments (semicolons work too), and also tries it with other data, to see whether it still works when the data changes. In the other exercises, you work in Excel with the lesson's file and type the result here.

At the end of the page you'll find the lesson's Bonus challenge: one more exercise, whose answer isn't in the book. You check it only here.

Exercise 1

For each of these cells, write down the error shown, its cause and how to fix it: D6, D7, B11, H4, H6 and column E. (Hint for H4: fix D6 first.)
Which error does D6 show?
Which error does D7 show?
Which error does B11 show?
Which error does H4 show?
Which error does H6 show?
What does column E show?
Show the answer

D6: #VALUE!; in C6 the number of people is written in words ("forty"): type the number 40. D7: #DIV/0!; C7 is empty and the formula divides by an empty cell: type 40. B11: #NAME?; in the formula (Excel shows it as =@IF(B10>6000,Yes,"No")) the text Yes has no quotation marks: type =IF(B10>6000,"Yes","No"), result Yes. H4: #N/A; the item looked up in H3 is called "Museums," but in the table it's "Museum": type Museum, result $8.00 (after fixing D6). H6: #REF!; the formula =D4+#REF! pointed to a deleted cell: type =D4+D5. Column E: #####; the column is too narrow for the dates: widen it by double-clicking the border between E and F.

Exercise 2

Once everything is fixed (40 people for each item): what does the guided tour in D7 cost per person? And what does H6 show?
What does the guided tour in D7 cost per person?
What does H6 show?
Show the answer

D7 = $6.25 ($250.00 divided by 40); H6 = $120.00 ($30.00 + $90.00).

Exercise 3

Imagine you don't know yet how many people will join the guided tour: C7 is empty. In D7, type a formula that shows To be confirmed instead of the error. Why wouldn't IFNA work here?
In cell D7
fx
Why wouldn't IFNA work here?
Show the answer

=IFERROR(B7/C7,"To be confirmed"). IFNA only acts on the #N/A error, and here the error is #DIV/0!.

Exercise 4

Without Excel: which error do these formulas return on the Trip sheet? a) =AVERGE(B4:B8); b) =B4/0; c) =VLOOKUP("Train",A4:D8,4,FALSE).
a) =AVERGE(B4:B8)
b) =B4/0
c) =VLOOKUP("Train",A4:D8,4,FALSE)
Show the answer

a) #NAME? (the function is called AVERAGE); b) #DIV/0!; c) #N/A (there is no Train item in the table).

Bonus challenge

The answer isn't in the book: you check it only here.

Trip sheet: fix all the errors as in exercises 1 and 2, with 40 people for each item. Then, in an empty cell, add up the five per-person amounts in D4:D8. How much does each traveler pay in total for the trip?
How much does each traveler pay in total?
Show the answer

After the fixes (40 in C6 and C7), =SUM(D4:D8) = $151.25: $30.00 (bus) + $90.00 (hostel) + $8.00 (museum) + $6.25 (guided tour) + $17.00 (meals). It's the same as dividing the total cost of the trip, $6,050.00, by 40. If D6 or D7 still shows an error, the SUM shows an error too: fix the causes first.