Leetcode Subarray From A Binary Switch