Java Comparator
时间:2014-05-05 23:32:10
收藏:0
阅读:444
1 Arrays.sort(points, new comparator()); 2 3 public static class comparator implements Comparator<Point> { 4 public int compare(Point p1, Point p2) { 5 return p1.x - p2.x; 6 }
评论(0)