input: Write a python function to find the maximum subarray sum.
  assert max_subarray_sum([-2, 4, -1, 5, 6]) == 14
  assert max_subarray_sum([-2, -3, 4, -1, -2, 1, 5, -3]) == 7
  assert max_subarray_sum([1, 2, 3, 4, 5]) == 15
output: def max_subarray_sum(arr):
      max_sum = float('-inf')
      current_sum = 0
      
      for num in arr:
          current_sum = max(num, current_sum + num)
          max_sum = max(max_sum, current_sum)
          
      return max_sum