I couldn't bring myself to do it for real with an actual rubber duck. But I recently came up with the concept of "comment ducking" which is when you just start writing a comment in the source code as if you were explaining to someone and that actually works as a substitute!