input: from typing import List
  
  def can_split_array(nums: List[int]) -> bool:
      """
      Given an integer array nums of even length, determine if it can be split into two subarrays nums1 and nums2 such that:
  
      - nums1.length == nums2.length == nums.length / 2
      - nums1 consists of unique elements
      - nums2 also consists of unique elements
  
      Return True if the array can be split in such a manner, otherwise return False.
  
      Examples:
      >>> nums = [1, 1, 2, 2, 3, 4]
      True
      >>> nums = [1, 1, 1, 1]
      False
  
      Constraints:
      1 <= nums.length <= 100
      nums.length % 2 == 0
      1 <= nums[i] <= 100
      """
output:     from collections import Counter
  
      n = len(nums)
      if n % 2 != 0:
          return False
  
      counts = Counter(nums)
      half = n // 2
  
      unique_elements = len([key for key, value in counts.items() if value == 1])
      if unique_elements >= half:
          return True
  
      duplicates_allowed = half - unique_elements
      duplicates_needed = len([key for key, value in counts.items() if value > 1])
  
      return duplicates_needed >= duplicates_allowed