Skip to content

Instantly share code, notes, and snippets.

@Atternatt
Last active September 21, 2017 04:55
Show Gist options
  • Save Atternatt/c19107a152dadbeaafbc605889944f17 to your computer and use it in GitHub Desktop.
Save Atternatt/c19107a152dadbeaafbc605889944f17 to your computer and use it in GitHub Desktop.
Extensions Basis
fun <T : Comparable<T>> List<T>.sort() {
Collections.sort(this)
}
list.sort();
val index = list.binarySearch(x);
val
Collection.sort(list);
int index = Collections.binarySearch(list, x);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment