摘要:
public class BinarySearch { //递归 public static int findData(int[] a, int b, int beginIndex, int endIndex) { if(a.length == 0 || a == null) { return 0; 阅读全文
摘要:
public class FindNum { public static boolean findANum(int[][] array, int target) { int row = array.length;//行数 int cloumn = array[0].length;//列数 int i 阅读全文
摘要:
public class StringReplace { public static void replaceSpace(String[] str, int length) { if(str == null || length <= 0) { return; } int originalLength 阅读全文
摘要:
public class QuickSort { public static int getMidIndex(int[] list, int low, int high) { int temp = list[low]; while(low < high) { while(low<high && li 阅读全文
摘要:
public class StackByQueue { private LinkedList<String> queue1; private LinkedList<String> queue2; public StackByQueue() { queue1 = new LinkedList<Stri 阅读全文
摘要:
public class QueueByStack { private Stack<Integer> stack1; private Stack<Integer> stack2; public QueueByStack() { // TODO Auto-generated constructor s 阅读全文
摘要:
public class MinNumberInRotatedArray { public int getMinNumInRotatedArray(int[] array) { if(array == null) { return -1; } int leftIndex = 0; int right 阅读全文