OCaml
# Expression
# let a = 1 in
let b = 2 in
a + b;;
- : int = 3
# 2.0 *. 3.14;;
- : float = 6.28
# Assertions
The expressionĀ assertĀ eĀ evaluatesĀ e. If the result isĀ true, nothing more happens, and the entire expression evaluates to a special value calledĀ unit. The unit value is writtenĀ ()Ā and its type isĀ unit. But if the result isĀ false, an exception is raised.