You have an integer array with elements initially in the range (), as well as a nonzero integer ().
You may perform the following operation as many times as you'd like (possibly zero): select an index and set .
Find the minimum number of operations to make all array elements distinct.