input: Write a function to improve the given Python program to reduce its time complexity. The original function calculates the maximum sum of any two elements in an array using a nested loop, which has a time complexity of O(n^2). The improved function should achieve the same result with a lower time complexity.
  
  ### Original Input:
  
  def find_max_sum(arr):
      max_sum = 0
      for i in range(len(arr)):
          for j in range(i+1, len(arr)): 
              max_sum = max(max_sum, arr[i] + arr[j])
      return max_sum
  
  
  ### Improved Output:
  
  def find_max_sum(arr):
      if len(arr) < 2:
          return 0
      max_sum = 0
      arr.sort()
      return arr[-1] + arr[-2]
  
  
  ### Assertions:
  assert find_max_sum([1, 2, 3, 4]) == 7
  assert find_max_sum([10, 10, 10, 10]) == 20
  assert find_max_sum([0, 0, 0, 0]) == 0
  assert find_max_sum([-2, -1, -3, -4]) == -3
  assert find_max_sum([5]) == 0
output: def find_max_sum(arr):
      if len(arr) < 2:
          return 0
      first_max = max(arr[0], arr[1])
      second_max = min(arr[0], arr[1])
      for num in arr[2:]:
          if num > first_max:
              second_max = first_max
              first_max = num
          elif num > second_max:
              second_max = num
      return first_max + second_max