4 ms·
One of the best post on FP I read was John Carmack's realisation that FP had a strong place in any code base [0]. It's a really valuable lesson to keep most fu
by keyle 3y ago
One of the best post on FP I read was John Carmack's realisation that FP had a strong place in any code base [0].
It's a really valuable lesson to keep most function as pure and stateless, but transformation of the existing state.
Build your entire codebase around this idea and frankly, abstraction will take care of itself.
[0] http://www.sevangelatos.com/john-carmack-on/ http://www.sevangelatos.com/john-carmack-on/
- syntheweave 3y agoCarmack's ideas did a lot for my code. He has good insights around what to take from different problem domains in order to get a result that gets right to the point and solves a specific category of error. You should never settle for "squishy" code that looks pretty just because: the code must do this, it cannot do that. Write it at the top of the function, and the best code will just go right to the goal without grabbing on to any boilerplate. That's something I was really missing in my earlier programming years, when all I saw were Java, Python and Ruby bloggers regurgitating OOP and Agile terms and I would try out their idea, marvel at the visible complexity of the abstraction, but then see it fail in a practical scenario. WTF.