Make decisions
Turn codes into words (SWITCH)
=SWITCH(A2,"N","North","S","South","Other")How it works in Excel
- A2 is the value being checked.
- Each pair is a code and the word to show.
- "Other" is used if nothing matches.
- This is shorter than nested IF when you are matching exact values.
- It needs Excel 2019 or later.
- For a long list of codes, use a lookup table instead.
The idea in general
It is a small translation chart built into one formula.
What I assumed
- The code is in A2.
Check the result on your own data before relying on it.