[WEBINAR] Bulletproof: How Today's Business Leaders Stay on Top

Rubber Duck Debugging

Definition - What does Rubber Duck Debugging mean?

In IT, the slang term “rubber duck debugging” has been created to describe an often effective yet simple strategy for debugging code. In rubber duck debugging, the programmer sits a small rubber duck (or other inanimate object) near them on a desk or near a computer, and explains the code to the duck line by line.

Rubber duck debugging is also known as rubberducking.

Techopedia explains Rubber Duck Debugging

The idea behind rubber duck debugging is simple – by explaining the process out loud, the programmer is able to better understand the nature of the code, the purpose of individual lines or modules, and what code is intended to do, in contrast to what it actually does. This idea is similar to the idea of proofreaders reading text aloud in order to catch errors, or mathematicians explaining an equation step by step in order to understand how the process works.

With rubber duck debugging, the idea is dressed up in a humorous way – the duck does not actually play any active role in the process. Again, it is the idea of verbal explanation that helps the developer to catch bugs in the code. For instance, the programmer could be “showing the duck” how a loop aggregates a certain string variable, and realize that one of the parameters is set wrong. Programmers can recognize fencepost errors and other types of errors while they are verbally going through the code and explaining it out loud. Rubber duck debugging has become somewhat commonly used term to describe this kind of explicatory process and why it is valuable to IT pros.

Share this:

Connect with us

Email Newsletter

Join thousands of others with our weekly newsletter

The 4th Era of IT Infrastructure: Superconverged Systems
The 4th Era of IT Infrastructure: Superconverged Systems:
Learn the benefits and limitations of the 3 generations of IT infrastructure – siloed, converged and hyperconverged – and discover how the 4th...
Approaches and Benefits of Network Virtualization
Approaches and Benefits of Network Virtualization:
Businesses today aspire to achieve a software-defined datacenter (SDDC) to enhance business agility and reduce operational complexity. However, the...
Free E-Book: Public Cloud Guide
Free E-Book: Public Cloud Guide:
This white paper is for leaders of Operations, Engineering, or Infrastructure teams who are creating or executing an IT roadmap.
Free Tool: Virtual Health Monitor
Free Tool: Virtual Health Monitor:
Virtual Health Monitor is a free virtualization monitoring and reporting tool for VMware, Hyper-V, RHEV, and XenServer environments.
Free 30 Day Trial – Turbonomic
Free 30 Day Trial – Turbonomic:
Turbonomic delivers an autonomic platform where virtual and cloud environments self-manage in real-time to assure application performance.