public void sink(int k) {
        while (2 * k <= N) {
            int j = 2 * k;

            if (j < N && isGreater(j, j + 1))
                j++;
            if (isGreater(j, k))
                break;
            swapArrayValues(j, k);
            k = j;
            this.comparisions += 2;
        }

    }