MCPcopy Index your code
hub / github.com/hustcc/JS-Sorting-Algorithm / sort

Method sort

src/java/main/BucketSort.java:10–16  ·  view source on GitHub ↗
(int[] sourceArray)

Source from the content-addressed store, hash-verified

8 private static final InsertSort insertSort = new InsertSort();
9
10 @Override
11 public int[] sort(int[] sourceArray) throws Exception {
12 // 对 arr 进行拷贝,不改变参数内容
13 int[] arr = Arrays.copyOf(sourceArray, sourceArray.length);
14
15 return bucketSort(arr, 5);
16 }
17
18 private int[] bucketSort(int[] arr, int bucketSize) throws Exception {
19 if (arr.length == 0) {

Callers

nothing calls this directly

Calls 1

bucketSortMethod · 0.95

Tested by

no test coverage detected