获取List集合中最大值的方法
时间:2017-04-24 18:38:42
收藏:0
阅读:2007
List ll = new ArrayList(); ll.add(new BigDecimal(1)); ll.add(new BigDecimal(4.99)); ll.add(new BigDecimal(5)); System.out.println("最大值: " + Collections.max(ll)); System.out.println("最小值: " + Collections.min(ll));
原文:http://www.cnblogs.com/mr-wuxiansheng/p/6758217.html
评论(0)