cellcraftEnter the quest map →
← Browse the curriculum
TEXT & DATA CLEANUP · ORIGINAL EXERCISE

Read the city code

Extract the two-character city code from B2, starting at character 5.

This quest practices MID using a fictional business dataset. Read the sheet below, then enter the interactive quest to write and check your formula.

Raw nameCodeEmailCityImported amount
aRI stone ORD-NY-204ARI@EXAMPLE.COMNew-York1200
bea moonORD-LA-105BEA@EXAMPLE.COMLos-Angeles850
CAM reed ORD-NY-306CAM@EXAMPLE.COMNew-York940
dev foxORD-AT-107DEV@EXAMPLE.COMAtlanta650
Play this quest · +70 XP →

Hints to get you started

  1. MID takes text, starting position, and character count.
  2. Character positions start at 1.
  3. Start at 5 and read 2 characters.
Show the worked solution
=MID(B2,5,2)

MID returns the NY section from ORD-NY-204.

Make the skill stick

After solving the task, explain what each reference does and why the formula answers the business question. Try the workbook download inside the quest to practice in your own spreadsheet app.

Explore the rest of this region →