1.list转化为数组
ArrayList<String> list=new ArrayList<String>();
String[] strings = new String[list.size()];
list.toArray(strings);
2.数组抓化为list
String[] s = {"a","b","c"};
List list = java.util.Arrays.asList(s);
标签:style nbsp new class arraylist 数组 strong array arrays
1.list转化为数组
ArrayList<String> list=new ArrayList<String>();
String[] strings = new String[list.size()];
list.toArray(strings);
2.数组抓化为list
String[] s = {"a","b","c"};
List list = java.util.Arrays.asList(s);
标签:style nbsp new class arraylist 数组 strong array arrays
原文地址:http://www.cnblogs.com/guanbin-529/p/8059174.html