摘要:
1.给定两个排序后的数组A和B,其中A的末端有足够的缓冲空容纳B。编写一个方法,将B合并入A并排序。 思路:从数组A和B的末端元素开始,将最大的元素放到数组A的末端。 public static void merge(int[] a, int[] b, int lastA, int lastB) { 阅读全文
posted @ 2018-01-08 18:07
struggleforit
阅读(691)
评论(0)
推荐(0)
2018年1月8日