Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

We have seen generalization too late -- rather, we have seen the need for it, but by definition, if it is left too late, it is impossible.

I personally have not seen premature optimization, but I may have led a charmed life.



I've always considered premature optimization to be a different problem than premature abstraction.

Premature optimization is something I struggle with - "hey, if I do this a different way it'll be faster/smaller!" And then I end up spending too much time optimizing one data area of code when I should just do it the easy way and move on to the next problem. I can always come back and optimize later when everything is working and I can see where the problem areas are, but the temptation is often hard to fight.

Premature abstraction is harder because abstracting existing code can be problematic and there's more of a chance to introduce bugs. It takes intuition and planning to get it right the first time around, and by the time you realize you should have abstracted something it's often too late to fix without rewriting a large chunk of your code and your teammates' code.




Consider applying for YC's Fall 2025 batch! Applications are open till Aug 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: