4 ms·
There are definitely scenarios where laziness is crucial. Haskell is the only mainstream language I know of where laziness is the default, but many languages of
by munchler 4y ago
There are definitely scenarios where laziness is crucial. Haskell is the only mainstream language I know of where laziness is the default, but many languages offer laziness when needed. (E.g. IEnumerable interface in C#.)
Monads are essential for "effectful" programming in a functional language. Imperative languages don't need monads, because everything they do is effectful (which leads to unnecessary side effects, and from there to a plethora of errors).
- epgui 4y agoI believe clojure has laziness out of the box as well. While both languages are functional, in contrast to Haskell, clojure doesn't have functors or monads. My understanding is that the same problem is essentially solved in a different way with macros.