You are viewing a single comment's thread. Return to all comments →
The R solution that goes with the setup I posted a minute ago is,
comparator = function(other) { if (score > other$score) { return(-1) } else if (score < other$score) { return(1) } else { return(ifelse(name < other$name, -1, 1)) } }
Seems like cookies are disabled on this browser, please enable them to open this website
Sorting: Comparator
You are viewing a single comment's thread. Return to all comments →
The R solution that goes with the setup I posted a minute ago is,