4 ms·
Invariants are the single most useful concept, in any programming environment, for making and keeping correct systems. They are necessary to reason mathematical
by moloch-hai 4y ago
Invariants are the single most useful concept, in any programming environment, for making and keeping correct systems. They are necessary to reason mathematically about systems. In interviews, I find them very inconsistently taught.
Invariants are not a substitute for anything else, but bolt on cleanly to whatever else you are doing. Whatever power functional programming offers comes from having numerous invariants baked in.