You are viewing a single comment's thread. Return to all comments →
Simple javascript solution:
function bigSorting(unsorted) { return unsorted.sort((a, b) => { if (a.length === b.length) { for (let i = 0; i < a.length; i++) { if (a[i] !== b[i]) return a[i] - b[i]; } } return a.length - b.length; }) }
Seems like cookies are disabled on this browser, please enable them to open this website
Big Sorting
You are viewing a single comment's thread. Return to all comments →
Simple javascript solution: