一 概述
代码
List<Integer> list = new ArrayList<>();
list.add(0);
list.add(1);
list = list.subList(0,1);
System.out.println("list = " + list);
结果
标签:回顾,List,list,subList,System,获取,add,println
来源: https://blog.csdn.net/calm_encode/article/details/122355583