Changing ternary quicksorts to use true ternary comparison which costs just one.