ALGORITHM
兮兮陆离
这个作者很懒,什么都没留下…
展开
-
单链表版桶排序
public class BucketSort implements AscSortInterface { @Override public int[] sortAsc(int[] arr) { if (null == arr || arr.length <= 1){ return arr; } // how many buckets int minVal = Arrays.stream(ar.原创 2020-05-24 10:46:48 · 199 阅读 · 0 评论 -
单链表版基数排序(支持负数)
import java.util.Arrays; import java.util.OptionalInt; public class RadixSort implements AscSortInterface { /** * -11 -12 -12827 0 12 7262 73 * * [1~10 11~20] * -9 ~ -0; 0 ~ 9 * both negative and positive * @param .原创 2020-05-22 07:54:18 · 334 阅读 · 0 评论