4 ms·
> there's likely a mental model in your head Yes, and unless there was a simple typo, the problem is the model in your head. Most bugs come from unchallenged a
by drewcoo 5y ago
> there's likely a mental model in your head
Yes, and unless there was a simple typo, the problem is the model in your head. Most bugs come from unchallenged assumptions.
- Jensson 5y agoKnowing that a particular bug can happen is usually enough to debug your mental model though. You just trace back to different assumptions you made and see which of them could cause this bug if wrong, and then fix it.
- wruza 5y agoIn my personal experience, most bugs come from changing a working code, especially at a refactoring. It mixes assumptions in an unpredictable way, because of chaotic code rearrangements and lots attention required to do that correctly. First-time code is much easier to challenge (if you ignore repl development phase which is not “code” yet).