Join Slack
Communities
Powered by
what about this? ``` compareBy { Math.abs(it.id - ...
# getting-started
j
james.cruz
11/21/2016, 8:36 AM
what about this?
Copy code
compareBy { Math.abs(it.id - destinationContext.destination.id) }
But note that would also sort everything else according to its difference from the destination id, so take that with a grain of salt.
Open in Slack
Previous
Next