3 ms·
OCaml is currently my language of choice. I love functional programming, been doing it for a while now, but it's nice to know that if I read an algorithm in a
by gnuvince 12y ago
OCaml is currently my language of choice. I love functional programming, been doing it for a while now, but it's nice to know that if I read an algorithm in a textbook, I can just implement it as-is instead of doing a translation to be purely functional (and sometimes having to fight to get back the asymptotic complexity). The module system is also absolutely great, and should be copied shamelessly by more languages.
- Peaker 12y agoHaskell doesn't ban imperative programming, it simply distinguishes it in the types.
- gnuvince 12y agoTrue, what I mean is that I can be "messy" in OCaml for the sake of expediency. In principle, I prefer Haskell's clean approach, in practice I'm a bad programmer who sometimes does naughty things.
- Peaker 12y agoWell, Haskell does force you to go and update your types about your effects, and fix the use sites to do proper lifting. I don't feel this costs much, though, so even in quick&dirty mode, I feel that Haskell is quite productive enough.