示例#1
0
  protected void TestInput(Integer[] input, int find, int expected) {
    w(Utils.PrintArray("Input:", input));
    w(" Search for " + find);
    // BinarySearch search = new BinarySearch();
    int pos;
    pos = Search(input, find);

    verifier.Verify("Found position", expected, pos);
  }
示例#2
0
 public void TestInput(Integer[] a, int expected) {
   w("FindMaxSum:" + Utils.PrintArray("", a));
   int max = FindMaxSum(a);
   verifier.Verify("FindMaxSum: ", expected, max);
 }