3 ms·
FP (specifically the Haskell / Scala style) is easier to reason about in large scale applications. In particular, when using distributed systems. Two reasons:
by Joof 7y ago
FP (specifically the Haskell / Scala style) is easier to reason about in large scale applications. In particular, when using distributed systems.
Two reasons:
Immutability guarentees that the variable name changes when the underlying data is changed. Therefore, we don't have to track complicated state through the program or in other threads and processes.
The type system catches many errors at compiletime. Fewer tests and easier to test. The trade-off is that the type system is slightly more complicated. Yes, it does have to be FP to handle this properly (type inference and higher order functions make it manageable).