|
|
|
|
|
by com2kid
1315 days ago
|
|
> Computational complexity allows us to quantify which algorithm is faster and better. But whether that algorithm was better implemented using FP concepts or OOP concepts, we don't know... we can't know. The CPUs code runs on are imperative, with a lot of complexities and details hidden from programmers by magic the CPU does involving things like reordering and automatic parallelization. However, none of the current languages are great at writing code that maps to how the CPU works. One can comment that functional programming does a better job of breaking up data dependencies, but imperative code can also do that just fine. The problem with mapping paradigms to performance is that none of the paradigm purists care about performance, end of the day they care about theoretical purity. CPUs don't care about paradigms, they care about keeping execution units busy and cache lined filled up. |
|
It's not theoretical purity. It's more tech debt. How do I code things in a way where there's zero tech debt. Such that all code can be re-used anywhere at anytime.