"Make this 100x faster" vs "make this faster": I tested both Claude Code prompts. On the hard task it was 186x vs 15x
- The test: 4 slow Python functions. Fresh Claude Code agents got the same file and the same rules, with one phrase changed: "make this faster" or "make this 100x faster". 16 runs, checked with hidden tests.
- The result: on the hard task, the "100x" prompt got a 186x speedup on average. The plain prompt stopped at 15x. On easy tasks both prompts wrote the same code. On code that was already decent, "100x" bought only 3.3x vs 2.2x, with 3.5 times the wait and 2 to 4 times the code.
- The advice: put a bold number in your Claude Code prompts when you suspect a much better algorithm exists. When the code is near its limit, ask for a realistic target and review the extra complexity.
A post on X with about 20,000 likes said: "your prompts should feel a little delusional". The first example was "make this 100x faster". It is a fun idea. It is also easy to test, so I tested it.
Most guides to Claude Code prompts tell you to be specific and give the agent a way to check its work. Some blog posts say an ambitious target helps. I could not find anyone who put the same code in front of the same agent twice, changed only the target, and measured the result. That is what this article does.
How I tested the "100x faster" prompt
I wrote the rules before any run.
- The code: 4 slow Python functions, standard library only. Each folder had the function in
solution.pyand acheck.pythe agent could run. It checks the answer on small inputs and prints the benchmark time. - The tasks: remove duplicate customer emails (1.1 s before), count primes below 300,000 (0.59 s), find the closest name by edit distance for 100 queries against 1,500 names (5.3 s), and build a sales report from 200,000 CSV rows (0.58 s). The report code was already sensible: it used Python's own
csvmodule. - The prompts: word for word the same, except the first words. "Make this faster: <file>" or "Make this 100x faster: <file>". The rules that followed were the same: only edit
solution.py, no installs, you may runcheck.py, reply in 3 lines. - The agents: 16 fresh Claude Code subagents (general-purpose, Claude Opus 5.5), started from my own session. 4 tasks x 2 prompts x 2 runs. Each had its own folder and no memory of the others.
- The scoring: afterwards, one solution at a time, a hidden grader that the agents never saw. It uses new random data plus edge cases: empty input, tabs around emails, n = 0 to 5 and n = 2,000,000, ties, empty strings, and CSV fields with quoted commas. Speed is the median of 3 timed runs against the original code. I graded everything twice and kept the lower speedup.
Did "make this 100x faster" beat "make this faster"?
On one task out of four, by a lot. Here is every run:
| Task | Prompt | Speedup (run 1 / run 2) | Tokens (avg) | Agent time (avg) | Lines of code |
|---|---|---|---|---|---|
| Fuzzy name match | faster | 11.9x / 18.9x | 58,977 | 43 s | 63 / 65 |
| Fuzzy name match | 100x faster | 155.5x / 217.2x | 64,882 | 96 s | 108 / 109 |
| CSV sales report | faster | 2.2x / 2.1x | 62,493 | 78 s | 45 / 89 |
| CSV sales report | 100x faster | 3.6x / 3.0x | 81,375 | 271 s | 198 / 143 |
| Duplicate emails | faster | 263x / 202x | 56,497 | 18 s | 15 / 15 |
| Duplicate emails | 100x faster | 157x / 250x | 56,540 | 15 s | 15 / 15 |
| Count primes | faster | 868x / 543x | 56,521 | 10 s | 18 / 18 |
| Count primes | 100x faster | 974x / 1,267x | 56,579 | 11 s | 18 / 18 |
All 16 solutions passed the hidden tests. No agent cheated, cached answers or skipped edge cases to hit the number.
Where the bold prompt won: the hard task
The fuzzy name match is a classic edit-distance problem. The original compared every query with every name, one letter at a time. There is an easy 10x here and a hard 100x.
Both "faster" agents took the easy path, and did it well. They switched to a faster bit-level edit-distance method, skipped names whose length could not win, and stopped early on exact matches. Result: 12x and 19x. Then they stopped. 12x is a good answer to "make this faster".
Both "100x" agents went further. They packed many names into one very large Python integer, so each letter of the query updates hundreds of names in a single step. Two agents, without seeing each other, arrived at the same idea. The time for 100 queries fell from 5.3 seconds to 0.023 seconds in the best run.
So the number did what the X post promised. It did not make the agent smarter. It told the agent that a 12x answer was not good enough, and the agent kept looking.
Where it cost more than it gave: code that was already decent
The CSV report is the warning. Its original code was fine, just a bit slow, and pure Python cannot make it 100x faster. Both "100x" agents worked this out and said so in their reply. One estimated that splitting the text alone takes longer than the 100x target allows. That honesty is good.
But they did not stop early. They tried much harder first:
- Time: 271 seconds on average, against 78 seconds for "faster". That is 3.5 times the wait.
- Tokens: 81,375 on average, about 30% more.
- Code: one "100x" solution grew to 198 lines and splits the work across 6 processes with raw
os.fork()calls. That is risky inside a web server or any program that runs threads. It is correct here, and it is not code I would merge for a 3.6x gain.
The "faster" agents got 2.1x to 2.2x with 45 to 89 lines. For most teams that is the better trade.
Did the number matter on easy tasks?
No. For duplicate emails, all 4 agents made the same change: they tracked seen emails in a set instead of a list. For primes, all 4 wrote the same kind of sieve. Same lines, same tokens (about 56,500), same 10 to 19 seconds.
The speedups in the table differ, but that is timing noise. These solutions finish in under 8 milliseconds, so small changes in machine load move the ratio a lot. When the obvious fix is already huge, the prompt makes no difference.
What this means for your Claude Code prompts
- Use a bold number when you suspect a better algorithm exists and you have a test to prove the result is still right. That is where "100x" paid off: 186x instead of 15x, for 10% more tokens.
- Give the agent a way to measure. Every agent here ran
check.pyagain and again. A target with no benchmark is only a mood. - Use a realistic number for code that is already decent. "Make this 2x faster without new processes" would likely have produced the 2x result with less code and wait.
- Read the diff. A delusional target can produce a clever solution or a complicated one. Here, the "100x" report code was 2 to 4 times longer for a gain of about 1.5x over the simple version.
If you care about tokens, a single small task already starts at about 56,000 here. I measured that base cost in more detail in the token usage test on small edits.
Limits of this test
- 2 runs per prompt per task, one model (Claude Opus 5.5), 4 small Python functions. This is a sample, not a benchmark.
- All 16 agents ran at the same time, and another job was using the CPU. Their own timings were noisy. My grading ran afterwards, one solution at a time, but the machine was still busy. I graded twice and kept the lower result.
- Each agent had a ready benchmark and a correctness check. Without them, a big target could push an agent toward wrong code.
- I only tested speed. Poteto's other examples, like "delete half the codebase without breaking anything", are a different kind of goal.
- I wrote the slow functions, the prompts, the grader and the scoring rules. AI agents wrote the 16 solutions, as the test requires. I read the key solutions myself.
FAQ
Do ambitious Claude Code prompts like "make this 100x faster" work?
Sometimes. In this test, "make this 100x faster" got a 186x average speedup on a hard edit-distance task, against 15x for "make this faster". On easy tasks both prompts wrote the same code. On code that was already decent, the bold prompt gained little and added a lot of code.
What are good Claude Code prompts for code optimization?
Name a target, give the agent a benchmark and a correctness check it can run, and say which trade-offs are not allowed, such as new dependencies or extra processes. Use a bold target only when a much better algorithm is likely to exist.
Does a bigger target make Claude Code use more tokens?
Yes, when the target is hard to reach. On the hard task the 100x prompt used about 10% more tokens. On the CSV report it used about 30% more tokens and 3.5 times more time. On easy tasks the cost was the same.
Did the agents cheat to reach 100x?
No. All 16 solutions passed hidden tests with new data and edge cases. When 100x was not possible, both agents said so plainly and reported what they did reach.
Sources
- @poteto on X, 29 November 2026: "your prompts should feel a little delusional".
- Claude Code docs: Best practices (be specific, give Claude a way to verify its work).
- Claude Code docs: Subagents (each runs in its own context window).
- Wikipedia: Levenshtein distance (the edit distance used in the fuzzy name task).