4 ms·
It's good to invest time in making decisions and coding them when it actually ends up making a positive difference to your work. Otherwise, by definition, it is
by danra 11y ago
It's good to invest time in making decisions and coding them when it actually ends up making a positive difference to your work. Otherwise, by definition, it is premature optimization. (of performance, design or otherwise.)
For instance, you often figure out you don't need a piece of code only after you've written and tested it, or after your thought process about the design has evolved. When you delete that code, it doesn't help anyone that a couple of hours ago you've invested five minutes in picking the "right" data structure for the implementation. The right data structure for unstable code is the one which lets you work with it and takes up the least of your time. As your code becomes more stable, it could then make sense to invest time in picking and coding a better data structure; it's less efficient to do so prematurely.