4 ms·
Simplicity will help me understand my code 6 months down the road; everything else is superficial and noise in comparison. You can't hold more than ~7 things a
by jeremiep 10y ago
Simplicity will help me understand my code 6 months down the road; everything else is superficial and noise in comparison.
You can't hold more than ~7 things at once in your head; once things are that simple you can see bugs a mile away, types or not.
The inverse is not true; types won't help you juggle 15 things at once and bugs will happily slide through the cracks. You're going to forget your codebase, types or not, and when you come back to it only simplicity will help you quickly figure out what you were doing with it.
- spion 10y agoI used to think like this, and I was wrong. As you add code to a software project, some of this code will be written when the problem is not well understood; thats inevitable. The solution will then need to be refactored or rewritten, the first of which is extremely painful in a dynamic language, even if you keep things simple. For example: if you implement a store that only sells electronic books will have a lot of assumptions regarding the selling and delivery process. Later the business wants to start selling physical things and needs to handle stuff like shipping costs, tracking and so on. For problems like online stores, the possible directions in which they can develop are well understood and its easier to plan ahead. For most other things, its not, and the ability to reorganise code to be usable in different ways is invaluable.