input: Write a function to return an array containing the smallest and greatest values from the input array. If the input array is empty, return an empty array.
  assert min_max([3, 4, 2, 8, 15, 6])==[2, 15]
  assert min_max([1, 1, 1])==[1, 1]
  assert min_max([-5, -2, 0, 5])==[-5, 5]
  assert min_max([10])==[10, 10]
  assert min_max([])==[]
output: def min_max(arr):
      if not arr:
          return []
      return [min(arr), max(arr)]