参考博文使用java.util.List.subList时最好小心点 List接口中定义: List<E> subList(int fromIndex, int toIndex); 英文注释: Returns a view of the portion of this list between the specified fromIndex, inclusive, and toIndex, exclusive. (If fromIndex and toIndex are equal, the…
List<String> mStrings=new ArrayList<>(); //初始化 for (int i = 0; i < 1020; i++) { mStrings.add(String.valueOf(i)); } List<List<String>> newStrings = new ArrayList<>(); if (mStrings.size() > 100) { if (mStrings.size() % 10…