Duplication Has Been Recognized for More Than 30 Years as The Bane of The Programmer's Lot. How does Duplication Cause Problems?
There is more code to maintain (a conceptual and physical burden) .Parts that vary are buried inside the parts that stay the same (a perceptual problem - it's hard to see the important stuff) .Code variations often hide deeper similarities - it will be hard to see the deeper solution among all the similar code.There's a tendency to fix a bug in one place and leave identical bugs elsewhere unfixed. When you see two variations of something, it's hard to know which variation is the right pattern or if there's a Good reason for the variations.