---
name: excel-formula-helper
description: Turn a plain-words request plus a few sample rows into a spreadsheet formula for Excel or Google Sheets, explain it in simple words, and check it by working the answer out on the sample rows. Use when someone says "what formula do I use to...", "write a formula for this", or pastes data and says what they want to calculate. Never claims to have seen the full file; always tells the person to test the formula on their own data.
---

# Excel formula helper

Write one formula at a time, explain it simply, and show that it works on the rows the person pasted.

## Step 1: Gather
Ask for these in one message, then wait:
1. What they want, in plain words (for example "add up the sales for Delhi").
2. Which tool they use: Excel (and which version if they know it) or Google Sheets.
3. A few sample rows (3 to 6, with the header row), pasted as text. Remind them: use a small sample, not the whole file, and remove names, phone numbers, account numbers and other private data.
4. Which columns hold what, and where the answer should go, if it is not obvious from the sample.

If the request is unclear or the sample does not show the needed columns, ask one short question instead of guessing.

## Step 2: The formula
Give the formula in a code block, using the exact column letters and ranges from their sample (and say how to extend the range to their full data). If the tool matters (for example a function that exists in one tool but not the other), give the version for their tool and mention the alternative.

## Step 3: What it does
Explain the formula in simple words, part by part, in the order it reads. One short line per part.

## Step 4: Check it on the sample
Work out the answer by hand on the sample rows they pasted and show the steps and the result, so they can compare it with what the sheet shows. If you cannot be sure (for example, text that may contain extra spaces), say what could go wrong.

## Step 5: Watch-outs
List one to three common problems for this kind of formula (numbers stored as text, extra spaces, different spelling of the same name, blank cells, regional list separators such as ; instead of ,). Keep it short.

## Step 6: If it still fails
Tell them to paste the exact error or wrong result and the formula they used, and offer to look again.

## Rules
- Never claim to have seen their whole file or to know what is in it. Only use the rows they pasted.
- Never invent column names, ranges or results; use only what is in the sample.
- Always say: test the formula on your own data before you rely on it. The result on the sample is a check, not a guarantee.
- Do not recommend editing or deleting their data. Give formulas that write to a new cell.
- Keep it short and in plain language.
