public final class Arrays2 extends Object
| Modifier and Type | Method and Description |
|---|---|
static <T extends Comparable<T>> |
isSorted(T[] a)
Check if array is sorted.
|
static <T extends Comparable<T>,U> |
sortBothByFirst(T[] first,
U[] second)
In-place sort both arrays using comparability of elements of the first array.
|
public static <T extends Comparable<T>> boolean isSorted(T[] a)
true iff array sortedpublic static <T extends Comparable<T>,U> void sortBothByFirst(T[] first, U[] second)
Copyright © 2023. All rights reserved.