Search⌘ K
AI Features

Special Array I

Try to solve the Special Array I problem.

We'll cover the following...

Statement

Given an integer array nums, determine whether it is special.

An array is considered special if every pair of adjacent elements nums[i] and nums[i+1] has different parity, meaning one is even and the other is odd.

Return true if nums is special, otherwise return false. ...