3 ms·
ml languages (sml, ocaml) support side effects through mutable references, and sequences in case you need it. Haskell aims for purity so you encode side effects
by agumonkey 10y ago
ml languages (sml, ocaml) support side effects through mutable references, and sequences in case you need it. Haskell aims for purity so you encode side effects as threaded state variables through functions (State and IO monad); other kind of side effects possible with this pattern too (Continuations, ...).