public static void quickShort(int array[], int low, int n) {
		int lo = low;
		int hi = n;
		if (lo >= n) {
			return;
		}
		int mid = array[(lo + hi) / 2];
		while (lo < hi) {
			while (lo < hi && array[lo] < mid) {
				lo++;
			}
			while (lo < hi && array[hi] > mid) {
				hi--;
			}
			if (lo < hi) {
				//swap
				swap(array, lo, hi);
			}
		}
		if (hi < lo) {
			int temp = hi;
			hi = lo;
			lo = temp;
		}
		quickShort(array, low, lo);
		quickShort(array, lo == low ? lo + 1 : lo, n);
	}