input: Write a function that computes the mean and median of an array given by the user. The function should return both the mean and the median as a tuple. If the length of the array is odd, the median is the middle element of the sorted array. If the length is even, the median is the average of the two middle elements of the sorted array. If the array is empty, the function should return (0, 0).
  def mean_median(arr): 
      if len(arr) == 0:
          return 0, 0
      
      arr_sum = 0 
      for i in range(len(arr)): 
          arr_sum += arr[i] 
          
      mean = arr_sum / len(arr)
          
      arr = sorted(arr) 
      
      if len(arr) % 2 != 0: 
          median = arr[len(arr) // 2]
      else:
          median = (arr[len(arr) // 2] + arr[len(arr) // 2 - 1]) / 2
          
      return mean, median
  
  assert mean_median([10, 15, 20, 25, 30, 35]) == (22.5, 22.5)
  assert mean_median([7, 3, 5, 2]) == (4.25, 4)
  assert mean_median([9, 3, 2, 4, 6]) == (4.8, 4)
  assert mean_median([]) == (0, 0)
output: def mean_median(arr): 
      if len(arr) == 0:
          return 0, 0
      
      arr_sum = 0 
      for i in range(len(arr)): 
          arr_sum += arr[i] 
          
      mean = arr_sum / len(arr)
          
      arr = sorted(arr) 
      
      if len(arr) % 2 != 0: 
          median = arr[len(arr) // 2]
      else:
          median = (arr[len(arr) // 2] + arr[len(arr) // 2 - 1]) / 2
          
      return mean, median