static bool TestOne() { var array = new[] { 616, 20, 0 }; QuickSort.Sort(array); return(QuickSort.IsSorted(array)); }
static bool TestFive() { var array = new int[0]; QuickSort.Sort(array); return(QuickSort.IsSorted(array)); }
static bool EmptyMassiveTest() { var array = new int[0]; QuickSort.Sort(array); return(QuickSort.IsSorted(array)); }
static bool ThreeElementsTest() { var array = new[] { 10, 5, -10 }; QuickSort.Sort(array); return(QuickSort.IsSorted(array)); }
static bool OneHundredElementsTest() { var array = new int[100]; for (var i = 0; i < array.Length; i++) { array[i] = 12; } QuickSort.Sort(array); return(QuickSort.IsSorted(array)); }
static bool TestThree() { var rand = new Random(); var array = new int[1000]; for (var i = 0; i < array.Length; i++) { array[i] = rand.Next(); } QuickSort.Sort(array); return(QuickSort.IsSorted(array)); }
static bool TestTwo() { var array = new int[100]; for (var i = 0; i < array.Length; i++) { array[i] = 32; } QuickSort.Sort(array); return(QuickSort.IsSorted(array)); }