Change the index of the element which was at position 0. Swap the element basically .
element = arr [ best_index ] NEW_LINE h [ element ] = initial_index NEW_LINE arr [ best_index ] , arr [ initial_index ] = ( arr [ initial_index ] , arr [ best_index ] ) NEW_LINE