2 ms·
monads were certainly a clever fix for the difficulties otherwise caused by passing around the world as a value. I might argue that laziness makes haskell some
by knome 1y ago
monads were certainly a clever fix for the difficulties otherwise caused by passing around the world as a value.
I might argue that laziness makes haskell something different than purely applicative.
It's not just pure values being passed around. It's a language built atop suspended self-caching invocable thunks getting knotted up and then firing off in chain reaction.
main = do
let
hello = foo world
world = bar hello
putStrLn $ show hello
putStrLn $ show world
where
foo v = [v]
bar v = length v