in reply to sort direction

You might look at Sort::Key and friends, which can sort numerically or string...ically, and also in reverse. I agree with [id://Perl Mouse] about the dangers of mixing numeric and string sort, unless you're really sure of your data.