human
Give me a Python function to test if an array contains an element.
assistant
Here is a Python function to test if an array contains an element

import numpy as np

def _contains(arr, element):
  """Helper that returns if array contains an element."""
  return element in arr

# Enter the array
arr = np.array([1, 2, 3, 4, 5])

# Calling the function
print((_contains(arr, 3)))

#Example Output
# True

#Remember to inspect code for bugs.