This question evaluates array-processing and combinatorial counting skills, focusing on reasoning about parity of element occurrences and efficiently counting qualifying contiguous subarrays.
Given an integer array nums, return how many contiguous subarrays contain an odd number of zeros. Provide an O(n) solution (e.g., using prefix parity counts of zero occurrences) and state its time and space complexity. Example: nums = [0, 0, 1, 0, 1] -> 4.