https://zhidao.baidu.com/question/1753810804914352748.html
https://www.cnblogs.com/chenpi/p/5552901.html
public class list {
public static void main(String[] args) {
List<Integer> list=new ArrayList<Integer>();
list.add(1);
list.add(2);
list.add(3);
list.add(4);
// int a= (int)list.get(0);
int a= list.get(0);
}
}
Iterator<Integer> itr = list.iterator(); while(itr.hasNext()) { int i = itr.next(); if (i > 5) { // filter all ints bigger than 5 itr.remove(); } }
拆箱装箱