2007年7月4日
摘要: HashMap map = new HashMap(); map.put("0201", "0201"); map.put("01", "01"); map.put("0304", "0304"); map.put("0101", "0101"); Obj... 阅读全文
posted @ 2007-07-04 11:19 kenty 阅读(22778) 评论(1) 推荐(1) 编辑
摘要: 二维数组排序实例: import java.util.*; public class TwoDimArrayTest { public static void main(String[] args) { String[][] arr = {{"B","Z","K"}, {"C","X","L"}, {"A","Y","M"}} ; //缺省(按0列升序) Arrays.sort(arr, new ... 阅读全文
posted @ 2007-07-04 10:46 kenty 阅读(840) 评论(0) 推荐(0) 编辑
摘要: java中的数组与集合的排序 两种需要排序的对象:数组和集合 1、集合 java.util.Collections类提供了排序方法sort(); static void sort(List list) Sorts the specified list into ascending order, ac... 阅读全文
posted @ 2007-07-04 10:07 kenty 阅读(1229) 评论(0) 推荐(0) 编辑
摘要: /* *@description : 实现任意两整数数组的按从小到大重组 * 先排序,再重组 *@Author : dalily *@Date : 2004-2-22 */ public clas... 阅读全文
posted @ 2007-07-04 09:54 kenty 阅读(2222) 评论(0) 推荐(0) 编辑