input: Write a python function to find the maximum sum of a contiguous subarray.
  assert find_max([-5, 2, 3, 4, 6, -8]) == 10
  assert find_max([-2, 1, -3, 4, -1, 2, 1, -5, 4]) == 6
  assert find_max([1, 2, 3, -2, 5]) == 9
output: def find_max(arr):
      max_so_far = arr[0]
      max_ending_here = arr[0]
      
      for i in range(1, len(arr)):
          max_ending_here = max(arr[i], max_ending_here + arr[i])
          max_so_far = max(max_so_far, max_ending_here)
      
      return max_so_far