I often explain to people about what I call ‘parrot programming’ . The most frequently effective method of debugging code is to have a buddy (who doesn’t even necessarily need to understand a thing about programming) sit ‘on your shoulder’ like a parrot, while you explain what you need to fix. They often never need to say a word – the mental act of framing the question in order to explain it to someone is enough to make you realise your mistake or realise a novel solution nine times out of ten.
And on the occasions that you go round the entire team and everyone is still stumped, you get to feel vindicated for having come unstuck in the first place!
On that topic, I wholeheartedly agree with everything in this short post by Mark Huot on HappyCog