记录一下Comparator的用法
Collections.sort(res,
new
Comparator<ArrayList<Integer>>() {
@Override
public
int
compare(ArrayList<Integer> o1, ArrayList<Integer> o2) {
if
(o1.size()<o2.size()){
return
1
;
}
else
return
-
1
;
}
});