Practice problems / Lookup & Reference

Fix #NAME?: the tuition lookup calls VLOKUP

Medium Lookup & Reference Debug
Description
Hints 0/4
Solutions 1
–
Test case
1
2
3
Reset
Submit
fx
A
B
C
D
E
F
G
1
2
3
4
5
6
7
8
9
10
Loading interactive spreadsheet...
Preparing grid cells and formula calculation engine
○ Ready Enter formula in highlighted cells, then click Submit.

Diagnose before you fix

Symptom H2 shows #NAME? instead of a course fee. The table in A2:C5 is intact.
Cause The cell calls VLOKUP. That name does not exist, so the engine stops before reading the range.
Repair Spell the function VLOOKUP. The table, the key cell G2 and the column index stay as they are.

The problem

Problem statement

The course fee in Fee cell H2 shows #NAME? instead of a price. The tuition table in A2:C5 is untouched. Diagnose the typo and repair the function name.

Repair the formula only — the course table must not be retyped.

Problem data

Show the sheet as a table (selectable, copyable)
The exercise data, as a table
ABCGH
1 Course codeCourseFeeCourse codeFee
2 C-101Excel Fundamentals320C-103
3 C-102SQL Basics280
4 C-103Data Visualization420
5 C-104Python for Analysts560

Notes

#NAME? means the spreadsheet cannot resolve a name used in the formula. Here the unknown name is the function itself: the cell calls VLOKUP, which does not exist. The engine fails on the name before it reads a single argument, so the table, the key cell and the column index are all innocent.

How to approach

Your answer goes in H2. On submit we re-run your formula against 3 different sets of input, so a hardcoded number will fail — the formula has to follow the cells.

  1. Target cell is H2 — it shows #NAME?, not a wrong fee
  2. Read the function name in the formula one letter at a time
  3. The grid knows the table; it does not know the name that was typed
  4. Shape: =VLOOKUP(G2, ?, 3, FALSE)

Official solutions

Show 1 solution — try it yourself first

Approach 1: correct the name

=VLOOKUP(G2,$A$2:$C$5,3,FALSE)

VLOOKUP is the real function name. Once the typo is fixed, the range, the column index and the exact-match flag all work as written.

Function guide

Related practice

FAQ

What does #NAME? mean?

The engine cannot resolve a name in the formula. Usually it is a misspelled function; sometimes it is a named range or table that was never defined. Check the spelling first, then the arguments.

The table is right there, so why the error?

Because the failure happens before the lookup runs. An unknown function name never gets as far as reading the range.