There is no “OO vs FP”, the two are orthogonal and coexist nicely.
9
100
4
254
OO involves the encapsulation of data and the functions that operate on said data. FP explicitly separates them. How will I know what goes where when working in this code?
3
7
Functions and the data structures they manipulate are inextricably bound no matter where they are positioned in the source code. At some level there is no difference between f(o) and o.f(). OO and FP meet at the level of the polymorphic interface.
2
1
2
At some level, there is no difference between any two Turing-complete programming languages

Apr 10, 2018 · 12:06 PM UTC

2
2
True. The question is whether we have to go all the way down to the turning machine to find the similarity; or whether there might be a higher level where the concepts come together with synergy. FP and OO do.
1