For teachers / Answer key
Answer key: Clean & Check Data
For teachers. This page is kept out of search engines and linked only from the teachers page. Students can see the same answers in a lesson with Show answer. Any formula that gives the right values counts.
1. Drop-down lists and data validation (Beginner, 6 min)
The Paid column should only ever say Yes or No. Select
B2:B6, click Data validation, choose List under Allow, type Yes, No in Source, and click Apply.B2:B6Data validation: List: Yes, No
Use it. Click
B2, open its list with the arrow (or Alt+Down), and choose Yes.B2Yes
Shows B2: Yes
The statuses are listed in
F2:F4. GiveC2:C6a list that reads them: select C2:C6 and set Allow to List with the Source=F2:F4.C2:C6Data validation: List from F2:F4
A list from a range stays up to date. Change
F4to Returned, then open the list inC2to see it.F4Returned
Shows F4: Returned
Rules are not only lists. An order holds between 1 and 20 boxes. Select
D2:D6, set Allow to Whole number, Minimum to 1 and Maximum to 20, and click Apply.D2:D6Data validation: Whole number between 1 and 20
Enter 12 in
D2.D212
Shows D2: 12
2. Spotting problems with IS functions (Intermediate, 5 min)
Start with the gaps. In
E2:E11, use ISBLANK to flag every item that has no count in column B.E2:E11=ISBLANK(B2)then copy it across the range
Shows E2: FALSE, E3: FALSE, E4: TRUE, E5: FALSE, E6: FALSE, E7: FALSE, and 4 more
Some counts arrived as text. They look like numbers, but they sit on the left of their cells. In
F2:F11, flag them with ISTEXT.F2:F11=ISTEXT(B2)then copy it across the range
Shows F2: FALSE, F3: TRUE, F4: FALSE, F5: FALSE, F6: FALSE, F7: TRUE, and 4 more
Column D multiplies each count by its unit cost, and two rows have broken. In
G2:G11, flag every value that is an error with ISERROR.G2:G11=ISERROR(D2)then copy it across the range
Shows G2: FALSE, G3: FALSE, G4: FALSE, G5: FALSE, G6: TRUE, G7: TRUE, and 4 more
Now turn the question round: a usable count is a real number. In
H2:H11, test each count with ISNUMBER.H2:H11=ISNUMBER(B2)then copy it across the range
Shows H2: TRUE, H3: FALSE, H4: FALSE, H5: TRUE, H6: TRUE, H7: FALSE, and 4 more
Finally, one column a person can scan. In
I2:I11, showCheckwhen the count is not a number or the value is an error, and nothing ("") otherwise.I2:I11=IF(OR(NOT(ISNUMBER(B2)),ISERROR(D2)),"Check","")then copy it across the range
Shows I2: (empty), I3: Check, I4: Check, I5: (empty), I6: Check, I7: Check, and 4 more
3. Finding duplicates (Intermediate, 5 min)
In
C2:C11, flag every email that appears more than once: count it across the whole list with COUNTIF, then test whether the count is greater than 1. Lock the list as$B$2:$B$11so it stays put as you copy down.C2:C11=COUNTIF($B$2:$B$11,B2)>1then copy it across the range
Shows C2: TRUE, C3: TRUE, C4: TRUE, C5: TRUE, C6: FALSE, C7: FALSE, and 4 more
To keep each person once, number the copies instead. In
D2:D11, use=COUNTIF($B$2:B2, B2). Only the start of the range is locked, so the range grows by one row each time you copy it down.D2:D11=COUNTIF($B$2:B2,B2)then copy it across the range
Shows D2: 1, D3: 1, D4: 1, D5: 2, D6: 1, D7: 1, and 4 more
Turn the copy numbers into a decision. In
E2:E11, showFirstwhere the copy number is 1, andRepeatotherwise.E2:E11=IF(D2=1,"First","Repeat")then copy it across the range
Shows E2: First, E3: First, E4: First, E5: Repeat, E6: First, E7: First, and 4 more
So how many different people signed up? In
B14, let UNIQUE strip out the repeats and count what is left with ROWS:=ROWS(UNIQUE(B2:B11))B14=ROWS(UNIQUE(B2:B11))
Shows B14: 6
4. Mapping codes with CHOOSE and SWITCH (Intermediate, 5 min)
Priority codes run from 1 (most urgent) to 4. In
E2:E9, turn each code into a name with CHOOSE: 1 isUrgent, 2 isHigh, 3 isNormaland 4 isLow.E2:E9=CHOOSE(C2,"Urgent","High","Normal","Low")then copy it across the range
Shows E2: Normal, E3: Urgent, E4: High, E5: Low, E6: High, E7: Normal, and 2 more
Channel codes are text, so CHOOSE can't help here. In
F2:F9, use SWITCH to mapEMtoEmail,PHtoPhoneandCHtoChat, withOtheras the default for anything else.F2:F9=SWITCH(D2,"EM","Email","PH","Phone","CH","Chat","Other")then copy it across the range
Shows F2: Email, F3: Phone, F4: Chat, F5: Email, F6: Other, F7: Chat, and 2 more
Which day was each ticket opened? WEEKDAY returns 1 for Sunday up to 7 for Saturday, which makes a perfect index for CHOOSE. In
G2:G9, nest the two to show short day names such asMonandTue.G2:G9=CHOOSE(WEEKDAY(B2),"Sun","Mon","Tue","Wed","Thu","Fri","Sat")then copy it across the range
Shows G2: Mon, G3: Tue, G4: Wed, G5: Fri, G6: Sat, G7: Sun, and 2 more
CHOOSE can return numbers too. Urgent tickets need a reply within 1 day, High within 2, Normal within 3 and Low within 5. In
H2:H9, add the right number of days to the date each ticket was opened.H2:H9=B2+CHOOSE(C2,1,2,3,5)then copy it across the range
Shows H2: Jun 5, 2025, H3: Jun 4, 2025, H4: Jun 6, 2025, H5: Jun 11, 2025, H6: Jun 9, 2025, H7: Jun 11, 2025, and 2 more
5. Text surgery with nested formulas (Advanced, 6 min)
Order references come in different lengths, but they always sit between
[and]. InE2:E9, cut each one out with MID, using FIND to locate both brackets.E2:E9=MID(A2,FIND("[",A2)+1,FIND("]",A2)-FIND("[",A2)-1)then copy it across the range
Shows E2: W-10482, E3: P-731, E4: W-10517, E5: M-88-2041, E6: W-10533, E7: P-746, and 2 more
How many tags does each message have? Count the commas and add 1. In
F2:F9, compare the length of the tags with their length once SUBSTITUTE has deleted every comma.F2:F9=LEN(B2)-LEN(SUBSTITUTE(B2,",",""))+1then copy it across the range
Shows F2: 2, F3: 2, F4: 3, F5: 1, F6: 2, F7: 1, and 2 more
Surnames are the last word of each name, but some customers have middle names, so there's no single space to split at. In
G2:G9, use the padding trick: SUBSTITUTE swaps every space for 50 spaces, RIGHT takes the last 50 characters, and TRIM strips off the padding.G2:G9=TRIM(RIGHT(SUBSTITUTE(C2," ",REPT(" ",50)),50))then copy it across the range
Shows G2: Lin, G3: Holt, G4: Okafor, G5: Sousa, G6: Owusu, G7: Berg, and 2 more
REPT has a sunnier use too. In
H2:H9, draw each satisfaction score as a bar by repeating the block character█as many times as the score in column D.H2:H9=REPT("█",D2)then copy it across the range
Shows H2: ██, H3: █, H4: ███, H5: ████, H6: ██, H7: █████, and 2 more
6. Repairing numbers and names (Intermediate, 6 min)
Half the crate counts in column B are text. In
D2:D9, turn every count into a real number with=VALUE(B2), and keep an eye on the total inD11.D2:D9=VALUE(B2)then copy it across the range
Shows D2: 6, D3: 4, D4: 10, D5: 8, D6: 3, D7: 12, and 2 more
VALUE can't read 54 kg, because the letters get in the way. In
E2:E9, delete thekgwith SUBSTITUTE first, then convert what is left with VALUE.E2:E9=VALUE(SUBSTITUTE(C2,"kg",""))then copy it across the range
Shows E2: 54, E3: 18.5, E4: 92, E5: 71, E6: 13.5, E7: 60, and 2 more
Now the supplier names. In
F2:F9, tidy them with=PROPER(TRIM(A2)), the pairing you met in the Working with Text track.F2:F9=PROPER(TRIM(A2))then copy it across the range
Shows F2: Hilltop Farm, F3: Brook Lane Dairy, F4: Hilltop Farm, F5: Hilltop Farm, F6: Brook Lane Dairy, F7: Orchard End, and 2 more
In
B14:B16, count each supplier's deliveries with COUNTIF, searching the clean names in column F.B14:B16=COUNTIF($F$2:$F$9,A14)then copy it across the range
Shows B14: 4, B15: 2, B16: 2
Sometimes case does matter, for example when another system will match names character for character. In
G2:G9, check which raw names were already typed exactly right with=EXACT(A2, F2).G2:G9=EXACT(A2,F2)then copy it across the range
Shows G2: TRUE, G3: FALSE, G4: FALSE, G5: FALSE, G6: TRUE, G7: TRUE, and 2 more