Never ask AI for the answer

How do you get unstuck with AI and still learn the problem?

Pasting a problem into a chatbot gives you a clean solution in ten seconds. Reading it feels like learning. Then the same problem comes back a week later and your mind goes blank.

The reason is simple. Interviews test recall under pressure, and you only build recall by struggling to produce the answer yourself. Reading skips that struggle.

So give the AI one job: hand over the smallest possible hint, and only after you've made a real attempt. Think of a ladder where each step gives away a little more, and you have to try again to reach the next one.

  • Hint ladder: A fixed order of help: a question first, then a nudge, then the technique's name, then pseudocode for one step.
  • Attempt: What you tried and where it broke, written down. It's the price of the next hint.
  • System prompt: Instructions that set the rules for a whole conversation. Here, the rule is: don't give me the solution.

Steps:

  1. Try for 15 minutes first. Paul Epps suggests about this long before asking. The number isn't magic, but it forces a real attempt.
  2. Write your attempt down. Two sentences: what you tried, and what went wrong. Often this alone unblocks you.
  3. Ask for level 1. A single question that exposes the flaw, with no hint.
  4. Try again before climbing. Change something first. A repeat of the same attempt earns nothing.
  5. Stop at level 4. If pseudocode for one step doesn't help, read a full solution. Then rebuild it tomorrow from memory.

Why the rule lives in code: Rules you hold in your head get dropped when you're tired. The small function below enforces them: no attempt, no hint. You can paste its prompt into any assistant, or wire it into the coach you build in the last path.

Prompt, The ground rules:

You are coaching me through a coding interview problem.
Never write the solution, corrected code, or solution pseudocode.
Ask one question at a time.
Give more revealing help only when I ask for the next level, and only after I describe a new attempt.
Don't tell me I'm right unless I've explained why.

Prompt, Attack my approach:

Here is my approach to the problem: [approach].
Ask the one question most likely to expose a flaw in it. Don't give your own answer. Wait for my reply, then ask the next one.

Code, The rule that keeps you honest. This is the whole ladder as code. It answers one question: have you earned the next hint?

/** No new attempt means no new hint. That rule stops the slide into reading answers. */
export function nextHint(state: LadderState | null, attempt: string): LadderState | { refused: string } {
  const tried = attempt.trim();
  if (tried.length < 40) return { refused: "Write what you tried and where it broke, in a sentence or two." };
  if (!state) return { level: 0, lastAttempt: tried };
  if (tried === state.lastAttempt) return { refused: "That's the same attempt. Change something, then ask again." };
  if (state.level >= HINT_LEVELS.length - 1) return { refused: "Out of hints. Read a solution, then rebuild it tomorrow from memory." };
  return { level: state.level + 1, lastAttempt: tried };
}
  • tried.length < 40: A rough test that you wrote something real. 'help' doesn't pass.
  • tried === state.lastAttempt: Asking again without changing anything earns nothing.
  • state.level >= HINT_LEVELS.length - 1: The ladder ends. After this, you read a solution and rebuild it tomorrow.

Code, The prompt it builds. The same rules, as text you can send to any assistant.

export function hintPrompt(problem: string, state: LadderState): string {
  return [
    "You are coaching me through a coding interview problem.",
    "Never write the solution, corrected code, or solution pseudocode.",
    `Problem:\n${problem}`,
    `What I tried:\n${state.lastAttempt}`,
    `Your task: ${HINT_LEVELS[state.level]}`,
  ].join("\n\n");
}
  • Never write the solution: Goes in every request, because long chats drift away from earlier rules.

  • state.lastAttempt: Hints depend on context. Without your attempt, the model can only guess where you're stuck.

  • HINT_LEVELS[state.level]: Asks for one level of help and no more.

  • Failure, Asking for 'just a small hint' repeatedly: Five small hints add up to the solution. Each one must follow a new attempt.

  • Failure, The AI ignores your rules: Long chats drift. Start a fresh chat for each problem and paste the ground rules again.

  • Failure, Never reading a solution: Staying stuck for hours teaches nothing either. Level 4 has a clear exit.

Why does reading an AI solution feel like learning when it isn't?
Understanding a solution you're reading is much easier than producing one from nothing. Interviews test producing it, and only struggling to recall builds that.
What earns the next hint?
A new attempt: you changed something and can say what broke. Asking again doesn't count.
When should you read the full solution?
After the last level still leaves you stuck. Then close it and rebuild the solution from memory the next day.

Sources: