!!
higher-order
%+ sort `(list @)`~[3 1 2] lth

sort orders a list by a comparison gate.

glossary

%+ calls a gate that takes two arguments.

%+(add 2 3) is 5.

irregular forms:

(gate a b) is %+(gate a b)

sort orders a list by a comparison gate.

(sort `(list @)`~[3 1 2] lth) is ~[1 2 3].

^- casts a value to a named type: it checks the value fits and relabels it.

^-(@ 42) is 42.

irregular forms:

a leading backtick cast - the type in backticks, then the value - is ^-

list is the type of a null-terminated sequence.

(list @) is a list of atoms; the empty list is ~.

:~ makes a null-terminated list.

:~(1 2 3) is ~[1 2 3].

irregular forms:

~[a b c] is :~(a b c)

lth asks whether the first atom is strictly less than the second.

(lth 5 3) is %.n.