Company: Wiley Edge
Difficulty: medium
Max Separations You are given an array containing an equal number of odd and even integers. A separation between adjacent values is valid when each resulting partition contains equal counts of odd and even values. Its cost is the absolute difference of the adjacent values. Find the maximum number of valid separations whose total cost is at most `K`. Input Format `N`, then `K`, then `N` integers. Output Format Print the maximum number of separations.