| Viewed 113 times

How I can Sort Numbers in Descending Order in JavaScript?


I need a function that takes any nonnegative number as an argument and returns it with its digits in descending order. Descending order is when you sort from highest to lowest.