Solution (source code)

= Solution

A <preorder> is a <binary relation> that is <reflexive> and <transitive>: $a\preceq a$, and $a\preceq b\preceq c$ implies $a\preceq c$.

A <partial order> is a <preorder> that is also an <antisymmetric relation>: $a\preceq b$ and $b\preceq a$ together imply $a=b$.

A <linear order>, also called a <total order>, is a <partial order> in which every two elements are comparable: \b[$a\preceq b$ or $b\preceq a$ for all $a,b\in A$].