摘要: 1.比较器 Comparable接口 自然排序 @Override public int compareTo(T t){ //自定义比较规则 //要求: this > t ,返回正整数 // this == t,返回0 // this < t,返回负整数 } Comparator接口 定制排序 @O 阅读全文
posted @ 2022-08-24 20:29 香菇无盐 阅读(53) 评论(0) 推荐(0)