Sort fact output

Closes #20