Skip to content

ReverseSortBy

Sorts a list in descending order by a key function.

$ wo 'ReverseSortBy[{1, -3, 2, -4}, Abs]'
{-4, -3, 2, 1}