I learnt this thumb rule while learning Ruby On Rails. I liked Ruby very much and found it very intelligent and smart. Whatever may be the reason for not pursuing with Ruby but I liked this concept of DRY.
I found this has nothing in specific with any development language but a general principle to increase efficiency at whatever you do.
An effort once invested should be preserved in such a way so as it can be re-used by you or someone next time.