Design an efficient algorithm to sort 5 distinct - very large - keys less than 8 comparisons in the worst case. You can\'t use radix sort.
I have written a C implementation of the solution to this problem which can be found here: Sorting 5 elements using 7 comparisons
My code is well commented with an explanation of why it is working.