using System.Collections.Generic;
public static void QuickSort(List<int> arr, int start, int end)
int pivotIdx = partition(arr, start, end);
QuickSort(arr, start, pivotIdx - 1);
QuickSort(arr, pivotIdx + 1, end);
public static int partition(List<int> arr, int start, int end)
for(int i=start; i<end; i++)
public static void Main()
List<int> data = new List<int> {8, 5, 7, 1 ,9 ,3};
QuickSort(data, 0, data.Count - 1);
public static void swap(List<int>data, int a, int b)