input: def is_array_even(arr): 
      if len(arr)%2 == 0:
          return True
      else:
          return False
  """
  Check whether the given array has an even or odd number of elements.
  >>> is_array_even([1, 2, 3, 4])
  True
  >>> is_array_even([1, 2, 3])
  False
  """
output:     return len(arr) % 2 == 0