Re:A Pythonista's Review of Haskell
by Areading314 on Friday January 31, 2020 @12:30AM
(#22199353)
I write Python for a living, and it is an astoundingly productive language. What it gets right is the compromise between functional, object-oriented, and imperative styles. I too have been fascinated by the "pure functional" type languages, but they always fall short when it comes to "real world" projects.
I think it’s definitely hard for practitioners to adjust to FP, especially when under the pressure to ship. I think a great opportunity to look for ways to apply FP would be in small utilities or libraries. I’m planning my next project in Python but if I’m fortunate to ship that I’ll see if I can circle back to Haskell and go from beginner to intermediate by building a small library.
Re:A Pythonista's Review of Haskell
by Areading314 on Friday January 31, 2020 @12:46AM
(#22199408)
If you're interested in FP, I highly recommend checking out Let Over Lambda. It made me realize that there is actually lot in common between OO and FP.
Weirdly, I never found functional programming Python anyhow enjoyable. It just doesn't seem to have enough facilities to support it, feels like a sort of anti-pattern on it.
You'd probably like ML (especially Ocaml) then. It can do all the crazy FP drugs (including lazy evaluation), but it's also painless to write normal imperative code in.
Syntax is a hair grotty though.
I started off FP with lodash, then moved to Python and built in functions, and I’ve tasted the benefits of applying functional programming in production, and so that’s what makes learning Haskell interesting and worthwhile to me. I’m looking forward to bringing what I’ve learned from Haskell towards the rest of the code I write, even if it’s not in Haskell.