First cut at sorting.