public static void rSort (int[] array, int start, int end)
    {
        if (start == end)
            return;

        for (int i = start; i <= end; i++) {
            if (array[start] > array[i]) {
                array[start] ^= array[i];
                array[i] ^= array[start];
                array[start] ^= array[i];
            }
        }
        rSort (array, start+1, end);
    }