3 ms·
A few things about the functional/oo divide became clear to me as I was implementing my last game, which I wrote more or less from scratch in Scheme using a hyb
by vincent-toups 7y ago
A few things about the functional/oo divide became clear to me as I was implementing my last game, which I wrote more or less from scratch in Scheme using a hybrid of functional and object oriented systems.
One important lesson is that Object Orientation tends to produce a bit of conceptual dissonance in new programmers. It seems to tell you that the solution to your problem is identifying the objects you're interested in and then translating that set of objects into code. This is almost never the optimal design. Typically a completely different set of objects needs to be implemented and then composed into your program. Objects fundamental to the domain of interest may not even appear as single objects in the implementation.
A lot of what people complain about w.r.t. OO programming is just related to inexperience, in other words.
Functional programming, on the other hand, asks you to construct your program out of much more fundamentally abstract pieces. There is less of a chance that you'll naively sally forth implementing your mental model directly. To some extent, that accounts for its nice properties.