input: Write a function to optimize the given objective function using the Nelder-Mead method from the scipy.optimize module. The function should return the optimized values of the variables. If the objective function is empty, the function should return an empty list.
  assert optimize()==[some_optimized_values]
  assert optimize()==[another_set_of_optimized_values]
  assert optimize()==[]
output: def optimize():
      from scipy.optimize import minimize
      
      def objective_function(x):
          return x[0]**2 + x[1]**2
      
      if objective_function is None:
          return []
      
      initial_guess = [1.0, 1.0]
      result = minimize(objective_function, initial_guess, method='Nelder-Mead')
      
      return result.x.tolist()