Apple Interview Question

Min number of swaps to sort the array