// // File: AutoTest.java // // Language: Java 1.02 // Description: Automatic testing of a "SkipList" proposed by William Pugh // // Tests run automatically on different skip lists. // You can edit the constant parameters in the array. // // Author: Thomas Wenger, Jan-7-1998 // import java.util.Random; // Randomizer to produce test input public class AutoTest { /////////////////////////////////////////////////////////////////////////// // array of constants to stear the test: // Make changes here to verify performance of other parameters // public static final float[] PROBABILITY = { 0.50f }; public static final int[] INITIAL_LOAD = { 20000, 40000, 80000 }; public static final boolean[] INPUT_IS_SORTED = { false, true }; public static final int NUM_OF_TEST_OPERATIONS = 1000; /////////////////////////////////////////////////////////////////////////// // main: // public static void main(String args[]) throws java.io.IOException { System.out.println("Testing skip-list. Please wait."); // perform tests for all kind of input keys: for (int sortSel=0; sortSel