4 ms·
Don't abstract it out until it's used in multiple places. Don't abstract it out using a complicated system, like inheritance, when you can use a function in a
by pqh 9y ago
Don't abstract it out until it's used in multiple places. Don't abstract it out using a complicated system, like inheritance, when you can use a function in a module. Don't abstract it out if it's superficially similar as opposed to actually the same thing.
Regarding the last point: iterators, good abstraction; averaging function, good abstraction. These things never change. But bad abstractions copy things that are only similar in appearance.