input: 
  from typing import List
  
  def minimum_cost_to_connect(sticks: List[int]) -> int:
      """
      You are given an array of integers representing the lengths of sticks. You need to connect all the sticks into one stick. The cost to connect two sticks is the sum of their lengths. You need to return the minimum cost to connect all the sticks into one.
      >>> minimum_cost_to_connect([2, 4, 3])
      14
      >>> minimum_cost_to_connect([1, 8, 3, 5])
      30
      """
  
output:     import heapq
  
      heapq.heapify(sticks)
      total_cost = 0
  
      while len(sticks) > 1:
          first_stick = heapq.heappop(sticks)
          second_stick = heapq.heappop(sticks)
          cost = first_stick + second_stick
          total_cost += cost
          heapq.heappush(sticks, cost)
  
      return total_cost