def mean(array):
  """
  Calculates the mean of the absolute values in a list of numbers
  
  Args:
    array (list): array which we want to calculate the mean
  
  Returns:
    float: mean of the absolute values of the elements of the array
  """
  sum = 0
  for element in array:
    sum += abs(element)
  return sum / len(array)