Rubber Duck Debugging
Updated 2026-07-30
Summary
Rubber duck debugging (or rubberducking) is a debugging technique in software engineering, wherein a programmer explains their code, step by step, in natural language—either aloud or in writing—to reveal mistakes and misunderstandings.
Definition
When a programmer cannot debug their code, they explain the code line by line to a rubber duck on the desk. Often, during the explanation, they discover the bug themselves. Scaffolding effect: externalizing thinking. When stuck, find a "listener" (even a duck) and state the problem aloud. The linear reorganization of language forces the brain to clarify logic, making tacit knowledge explicit.
Introduction
How to use
Externalize thinking. When stuck, find a "listener" (even a duck) to state the problem. The linear reorganization of language forces the brain to clarify logic, making tacit knowledge explicit.
Mechanism
Same as rubber duck debugging: externalizing the explanation forces clarification of logic, making hidden errors explicit.
Practice
In progress 0/4Practice this model in one real situation:
Cases
- When stuck, explaining once locates a null pointer; before writing documentation, verbalize first.
Common pitfalls
- Thinking that a real person is required; being embarrassed to "talk to an object" and missing the benefit.
Sources
Source support: Explicit
References currently contain only Wikipedia links; primary sources still need review.
- en.wikipedia.orghttps://en.wikipedia.org/wiki/Rubber_duck_debuggingverified
account_treeGenealogyexpand_more
PRIVATE NOTES · Only visible to you
SAVED Q&A
ENTRY Q&A · Private saving available
Ask with a clear boundary
thinkingmodels answers from published entry context only.
Your question is sent to thinkingmodels. The answer uses public entry context only.
RELATED MODELS