What's the best programming language for coding agents?
TL;DR Highlight
Re-testing the claim that dynamic languages save tokens on larger tasks showed it doesn't hold up
Who Should Read
A backend developer choosing a language for coding-agent work based on token cost
Core Mechanics
- Easy-problem results don't generalize
- The post claiming dynamic languages use 1/2 to 1/3 the tokens is based on trivial Rosetta Code problems.
- J averaged 70 tokens versus 109 for Clojure, and C versus Clojure was a 2.6x gap.
- As with caveman mode, such big gaps vanish on larger problems.
- A zstd decoder eval re-tested it
- Agents got only the RFC and had to implement a complete zstd decoder without tests.
- Runs used GPT-5.6 Sol at medium and ultra effort.
- At medium, dynamic languages looked better on cost versus score.
- At ultra, results were mixed and a couple of static languages did best.
- Weird-language supremacy didn't appear
- Obscure languages and assembly scored poorly.
- More popular languages had weak-to-moderate correlation with higher correctness and lower cost.
- The author says mainstream languages are the safer bet for ordinary users.
- A Pandoc task gave the same picture
Community Reactions
- Experience that Go works well with LLMs
- One commenter found one dominant way to write things, consistent training data, and fast compile and lint cycles meant fewer correction requests.
- They said LLMs default to Python and must be repeatedly told to use Go.
- Opinion that MirrorCode also found small language gaps
- It compared Python, C, Rust, Go, OCaml, and Ada on 19 long tasks with little difference in solve rates.
- Successful Ada solutions used about 25% more tokens than average.
- Opinion that token efficiency misses whole-session cost
- Most tokens are spent outside code output, so a token-efficient language can be worse overall.
- TOON reportedly was a wash across whole sessions.
- Opinion that verifiable structure matters more than language
- Components with verifiable contracts make code easier for LLMs regardless of language.
- Another commenter suggested splitting by Python, Go, and TypeScript to keep logic from blurring across layers.
How to Apply
- Write exact build and test commands into agent instructions
- Today, add exact calls like cargo or go test to AGENTS.md or CLAUDE.md.
- Cut the time and tokens wasted on repeated wrong-argument calls.
- Run 2-3 real tasks before picking a language
- Run each candidate language on non-trivial tasks of your own under identical conditions.
- Record correctness, cost, and time together.
- Compare obscure languages against mainstream ones first
- Before adopting an unusual dense language, run the same task in a mainstream language.
- Prefer languages your team can read and review.
Try It
# Paste into Claude Code or ChatGPT (simplified version of the post's method)
You are a coding agent. Implement the task below in both {{language A}} and {{language B}}.
Task: {{task description, non-trivial}}
For each language, report in a table:
1) Whether tests pass
2) Number of fixes needed for compile/runtime errors
3) Approximate code length
4) Where you got stuck
At the end, state the conclusion applies to this one task only and do not generalize.
Next to try: swap in another task and repeat the comparison.Terminology
Related Papers
The Judge Can Debias Itself: Awareness and Self-Debiasing for Reliable LLM-as-a-Judge
Warning an LLM judge about bias or letting it self-critique improved 20 of 21 model–bias combinations.
90% of US working hours are spent on tasks not covered well by AI benchmarks
Mapping 29 benchmarks to job tasks shows 90% of US working hours lack good coverage
Postgres 19 delayed after AI reviewers find more bugs than humans can fix
LLM code review surfaced so many bugs that Postgres 19 slipped to November and 8-10 features were reverted
Show HN: Gemini 4 Argon plays StarCraft
LLMs wrote StarCraft bots in one hour; GPT-6 Astra scored highest.
A Plausible Explanation Is Enough to Mislead Multimodal Judges
Adding plausible explanations to fixed answers cut MLLM judges' wrong-answer rejection by 12.7–13.8 points.
Neural networks are clean
Looking at neurons directly shows most have one main job, challenging superposition.