Least-to-Most Prompting: Solving Hard Problems by Building Up From Easy Ones
2026-09-25
Chain of thought prompting taught language models to reason step by step, and it works well when the test problem looks like the examples you showed the model. It struggles when the test problem is harder than the demonstrations. A model shown three-step arithmetic often fails on a five-step version of the same task. This is the easy-to-hard generalization gap, and it is exactly where chain of thought runs out of room. In 2022, Denny Zhou and colleagues at Google introduced least-to-most prompting (arXiv 2205.10625, later published at ICLR 2023) to close it. The idea is simple to state: do not ask the model to solve the whole problem at once. Ask it to break the problem into smaller pieces, then solve those pieces one at a time.
The Gap Chain of Thought Leaves Open
The weakness is compositional generalization. A model can learn the individual operations a task requires and still fail to combine them into a longer chain than it has seen. On the SCAN benchmark, which maps natural language commands to action sequences, chain of thought prompting with code-davinci-002 reached only 16.2% accuracy, because the test commands compose primitives into sequences longer than the examples. The reasoning steps are all individually learnable, but stringing enough of them together in one pass is where the model breaks down. Least-to-most prompting was designed around this observation: if the hard part is length and composition, then reduce every problem to a series of problems short enough for the model to handle reliably.
Two Stages: Decompose, Then Solve
Least-to-most prompting splits the work into two prompting stages, each driven by its own few-shot examples.
- Decomposition: the model is prompted to break the original problem into an ordered list of simpler subproblems, arranged from least to most complex, so that later subproblems depend on earlier ones.
- Sequential solving: the model works through the subproblems in order, and the answer to each solved subproblem is appended to the prompt as context for the next one.
The name captures the ordering. You solve the least complex subproblem first, and each answer becomes a building block for the next. By the time the model reaches the hardest subproblem, the earlier answers have already done most of the setup, so the final step is small. This is different from chain of thought, where the model produces one continuous reasoning trace in a single generation. Here the reasoning is staged across multiple calls, and the intermediate results are made explicit and reusable.
Why Solving in Sequence Matters
The reason this helps is that it changes what the model has to do at any one moment. In a single pass, a model must hold the entire problem structure in its head and execute every step without a mistake compounding. In the least-to-most setup, each subproblem is short, and the answers to prior subproblems are supplied as verified context rather than re-derived. The model never has to keep more than one small step in working memory at once. This is why the approach shines on problems where difficulty scales with length: longer inputs simply produce more subproblems, not harder individual ones. The method also composes naturally with chain of thought, since each subproblem can itself be solved with a short reasoning trace.
The Numbers on SCAN and Beyond
The headline result is on SCAN. Using least-to-most prompting with 14 exemplars, code-davinci-002 reached at least 99% accuracy across the splits, reported around 99.7%, compared to 16.2% for chain of thought on the same model. That is not a marginal gain. The authors also noted that this prompting-only approach outperformed specialized neural-symbolic models that had been trained on more than 15,000 examples, while least-to-most used only a handful of demonstrations and no fine-tuning. On the last-letter-concatenation task, another test of length generalization, the gap widens as inputs grow: on lists of length 12, chain of thought scored 31.8% while least-to-most reached 74.0%. The paper reports gains on math word problems as well, including GSM8K and DROP, with the advantage largest on problems that require the most solving steps.
One caveat worth keeping in mind: these figures come from the original paper on specific 2022-era models and benchmarks, and the exact numbers shift with newer models and prompt variations. The direction of the result, that decomposition helps most as problems get longer and more compositional, has held up better than any single accuracy figure.
When to Reach for Least-to-Most
Least-to-most is worth trying when your task has clear internal structure and the failures you see are length failures rather than knowledge failures: the model can do a two-step version but not a six-step one, or it handles short inputs but degrades on long ones. Multi-hop questions, symbolic manipulation, and staged calculations are natural fits. It is less useful when a problem cannot be cleanly decomposed, or when a single well-chosen chain of thought already succeeds, since the two-stage setup adds prompting overhead and extra model calls. Treat it as one tool in a family that includes decomposed prompting, self-ask, and plan-and-solve, all of which trade a single monolithic generation for a structured sequence of smaller ones. PromptingIndex will keep tracking how these decomposition strategies perform as models grow more capable of handling long compositions in a single pass.
Put these ideas to work.
Browse the prompt library