input: Write a function to find the maximum element in an array of numbers. If the array is empty, return None. The function should take in an array of integers as its parameter and return the maximum element as an integer.
  
  assert find_max_element([1, 43, 78, 3, 92, 42]) == 92
  assert find_max_element([-5, -10, -3, -1]) == -1
  assert find_max_element([]) == None
  assert find_max_element([2]) == 2
  assert find_max_element([10, 20, 30, 40, 30, 20, 10]) == 40
output: def find_max_element(arr):
      if not arr:
          return None
      return max(arr)