Пример #1
0
        private static void QuickSortSequence()
        {
            Sorting opt = ShowSortingOption();

            Console.WriteLine("Input space separated integers to sort:");

            int[] toSort = ReadInput();

            if (opt == Sorting.ASC)
            {
                toSort = QuickSort.SortAsc(toSort);
            }
            else
            {
                toSort = QuickSort.SortDesc(toSort);
            }

            Console.WriteLine("Sorted sequence:");
            PrintArray(toSort);
        }