4 ms·
> and force developers to untangle the additional logic that was introduced to remove dupes. Additional logic is only needed when code is almost duplicated, an
by dragonwriter 5y ago
> and force developers to untangle the additional logic that was introduced to remove dupes.
Additional logic is only needed when code is almost duplicated, and that is where the question arises of whether what is happening is best viewed as a different “version” of some common process, or a different basic process that has similarities.
Actual duplication doesn't require additional logic to remove duplication; and even near dupes often don’t require distinct (i.e., branching) logic if the language offers the right abstraction facilities.