请输入您要查询的百科知识:

 

词条 Rubber duck debugging
释义

  1. In popular culture

  2. See also

  3. References

In software engineering, rubber duck debugging is a method of debugging code. The name is a reference to a story in the book The Pragmatic Programmer in which a programmer would carry around a rubber duck and debug their code by forcing themselves to explain it, line-by-line, to the duck.[1] Many other terms exist for this technique, often involving different inanimate objects.

Many programmers have had the experience of explaining a problem to someone else, possibly even to someone who knows nothing about programming, and then hitting upon the solution in the process of explaining the problem. In describing what the code is supposed to do and observing what it actually does, any incongruity between these two becomes apparent.[2] More generally, teaching a subject forces its evaluation from different perspectives and can provide a deeper understanding.[3] By using an inanimate object, the programmer can try to accomplish this without having to interrupt anyone else.

In popular culture

{{Rquote |1=right
|2=Insights are often found by simply describing the problem aloud.
|3=Duck |4=Quack Overflow
}}

On April 1, 2018, Stack Exchange introduced a rubber duck avatar on their websites as a new feature called Quack Overflow. The duck appeared at the bottom right corner of the browser viewport, and attempted to help the visitor by listening to their problem and responding with a solution. However, the duck merely produced a quack sound after apparently thinking and typing. It referenced rubber ducking as a powerful method for solving problems.[4] Some confused visitors seeing the duck for the first time thought that a malware program had been installed in their computer before realizing it was an April Fools' Day joke.[5]

{{clear}}

See also

{{Portal|Computer programming}}
  • Code review
  • Pair programming
  • Socratic method
  • Software walkthrough
  • The Aha! effect
  • Think aloud protocol

References

1. ^{{Cite book | isbn = 978-0201616224 | url = http://pragprog.com/the-pragmatic-programmer | title = The Pragmatic Programmer: From Journeyman to Master | publisher = Addison Wesley}} p. 95, footnote.
2. ^{{Citation | url = http://www.sjbaker.org/humor/cardboard_dog.html | title = The Contribution of the Cardboard Cutout Dog to Software Reliability and Maintainability | last = Baker | first = SJ}}.
3. ^{{cite web|last1=Hayes|first1=David|title=The Psychology Underlying the Power of Rubber Duck Debugging|url=http://pressupinc.com/blog/2014/06/psychology-underlying-power-rubber-duck-debugging/|website=Press Up|accessdate=3 July 2015|date=25 June 2014}}
4. ^{{cite web|title=Stack Exchange has been taken over by a rubber duck! |url=https://meta.stackexchange.com/a/308578 |website=Meta Stack Exchange |accessdate=1 April 2018 |date=31 March 2018}}
5. ^{{cite web |last1=Purushothaman |first1=Praveen Kumar |title=Quack Overflow - Stack Overflow's take on April Fool! |url=https://blog.praveen.science/quack-overflow-stack-overflows-take-on-april-fool |website=Adventures (Blog) |accessdate=1 April 2018 |date=31 March 2018}}

1 : Debugging

随便看

 

开放百科全书收录14589846条英语、德语、日语等多语种百科知识,基本涵盖了大多数领域的百科知识,是一部内容自由、开放的电子版国际百科全书。

 

Copyright © 2023 OENC.NET All Rights Reserved
京ICP备2021023879号 更新时间:2024/11/11 22:39:14