TreeSet:排序和去重以Comparable计算的值为准,equals和hashcode无效。
HashSet、LinkedHashSet:去重以equals和hashcode为准。
posted on 2022-07-22 07:52 谦虚好学每一天 阅读(125) 评论(0) 收藏 举报