摘要: 在使用 诸如 list001.stream().distinct().count()统计列表中不同元素的个数时,不要忘记了要重写hashCode()和equals()方法。 因为distinct()是Stream接口的方法。distinct()使用hashCode()和equals()方法来获取不同 阅读全文
posted @ 2019-11-10 19:00 helloHKTK 阅读(2297) 评论(0) 推荐(0) 编辑