Given an integer array nums, move all the even integers at the beginning of the array followed by all the odd integers. Return any array that satisfies this condition.
while left < right: if nums[right] % 2 == 0and nums[left] % 2 == 1: nums[right], nums[left] = nums[left], nums[right] left += 1 right -= 1 if nums[left] % 2 == 0: left += 1