摘要: 最近代码中需要对两个数组求交,想当然便用到了List中的retainAll函数,但要将将数组转换成list。代码如下:String[] abc = new String[] { "abc", "acd", "add" }; String[] abd = new String[] {"acd", "cd", "de"}; List abcList = Arrays.asList(abc); List abdList = Arrays.asList(abd); abcList.r 阅读全文
posted @ 2014-03-17 00:15 涂墨留香 阅读(3079) 评论(0) 推荐(0) 编辑