News for hackers. Stuff that matters.
Re:Ask HN: What is the most beautiful piece of code you've e... by brokencode on Monday October 28, 2019 @01:37AM (#21374548)
I don’t see how this is a great example of how functional programming sucks. It is easy in any programming language to build a slow sorting algorithm. The fact that you need to use different algorithms with immutable data is irrelevant. You need to use different algorithms for pretty much any type of data structure.

Functional programming makes a different set of tradeoffs than imperative programming. You have to work harder to get peak performance, but in many cases it is actually quite performant. Just look at how fast Elm is for web applications, and how that approach allows for a time-traveling debugger and virtually no crashes.

There are no comments on this comment yet.