Find the minimum value in the first half of an array and find the maximum value in the second half.
Implement find_half_extremes(nums), returning [minimum_first_half, maximum_second_half]. The first half contains indices 0 through len(nums) // 2 - 1; the second half starts at len(nums) // 2, so odd-length arrays place the extra element in the second half.
The input contains at least two integers. Return the result without modifying the input array.
def find_half_extremes(nums):