3 ms·
I use a similar approach: first code, then take a refactoring session and look if some repetitive code can be "condensed" in a common method. By the way the co
by daitangio 6y ago
I use a similar approach: first code, then take a refactoring session and look if some repetitive code can be "condensed" in a common method.
By the way the copy-pasta code is very resilient: a bug introduced in one place cannot spread, because the other code is duplicated and old.
Instead if you have too much condensed code, you end up with complex method which are difficult to maintain, because you have a huge "coverage land of code", and you get scared when you need to change it.