Talking to AI · 05

Tell it what "done" looks like

Outcome

By the end, you'll be able to shape Claude's reply — its length, format, and tone — just by asking for it directly.

Concept

Claude doesn't know how you want an answer packaged unless you say so. Want a numbered list instead of a wall of text? A two-sentence summary instead of an essay? Plain language instead of jargon? Ask for exactly that, in the same message as your question — Claude will follow the spec.

Build the prompt, step by step

Step 1 of 4

The ask

Explain what a "for loop" does in programming.

What comes back

A for loop is a control flow statement that allows you to execute a block of code repeatedly based on a specified condition or sequence. It iterates over a range of values, a collection, or until a condition is met, executing the loop body each time. For loops are fundamental in programming and are used in virtually every language, from Python and JavaScript to C++ and Java. They are particularly useful when you know in advance how many times you want to repeat an action, such as processing each item in a list, generating a sequence of numbers, or performing a calculation multiple times. The basic structure typically includes an initialization, a condition check, and an increment or update step.

Try it

Open claude.ai and try this prompt:

Prompt

Explain what a "for loop" does in programming. Use exactly 3 bullet points, keep each under 20 words, and avoid jargon.

What to look for: Check whether Claude actually followed the spec — exactly 3 bullets, each one short, no jargon. Then ask the same question again without the format instructions and compare.

Takeaway

If you care how an answer is shaped — length, format, tone — say so in the prompt; don't leave it to chance.

Your turn

This prompt makes Claude guess. Rewrite it so it has output specification to answer your actual situation — the checklist tracks what you add.

The weak prompt

Explain how photosynthesis works.

What you've added

  • Names a formatAsk for a list, a table, steps, JSON.
  • Names a lengthCap it: three sentences, under 100 words.
  • Names a structureSay what goes where: start with the summary, then the detail.
  • Names the tone or audiencePitch it: for a 10-year-old, plain English, formal.
Edit the prompt above to check it.

Practice

Practice with Claude

Try what this tutorial teaches. Conversations aren't saved.

Ask a question about working with AI, or paste a prompt to try — Claude will reply and point out where it could be sharper.


Don't make it guessTreat wrong answers as data