John Carmack on Functional Programming (via)
A large fraction of the flaws in software development are due to programmers not fully understanding all the possible states their code may execute in. In a multithreaded environment, the lack of understanding and the resulting problems are greatly amplified, almost to the point of panic if you are paying attention. Programming in a functional style makes the state presented to your code explicit, which makes it much easier to reason about, and, in a completely pure system, makes thread race conditions impossible.
A significant part of John Carmack’s intelligence is his ability to recognize the importance of having principles while not shunning pragmatic tradeoffs.
Recent articles
- pick is the single-value version of pluck in Rails - 26th November 2024
- Rails ActiveRecord has a .sole method - 26th November 2024
- NASA's Dragonfly probe to Saturn's Titan in 2028 - 26th November 2024