Pregunta de entrevista de Pendo

Even Subarray. Question on hackerrank Medium Difficulty