λ

2.8: Chaining expressions for side effects

In Standard ML, everything is an expression which returns a result, but you may chain multiple expressions in an imperative-like form for their side effects by separating them by semicolons. The result of these chains is the last expression in the block.

(* examples/chaining.sml *)