input: 
  def optimize_params(params: 'Params', ranges: int) -> 'Params':
      """ Optimize the given Params class instance by finding the best combination of a, b, and c within a specified range.
      The optimization is based on maximizing the sum of a, b, and c.
      >>> optimize_params(Params(a=1, b=2, c=3), ranges=10)
      Params(a=1, b=2, c=3)
      >>> optimize_params(Params(a=-5, b=0, c=5), ranges=5)
      Params(a=-3, b=-1, c=7)
      """
      best_score = get_result(params)
      best_params = params
      for a in range(params.a - ranges, params.a + ranges + 1):
          for b in range(params.b - ranges, params.b + ranges + 1):
              for c in range(params.c - ranges, params.c + ranges + 1):
                  current_params = Params(a=a, b=b, c=c)
                  score = get_result(current_params)
                  if score > best_score:
                      best_score = score
                      best_params = current_params
      return best_params
  
output:     best_score = params.a + params.b + params.c
      best_params = params
      for a in range(params.a - ranges, params.a + ranges + 1):
          for b in range(params.b - ranges, params.b + ranges + 1):
              for c in range(params.c - ranges, params.c + ranges + 1):
                  current_params = Params(a=a, b=b, c=c)
                  score = a + b + c
                  if score > best_score:
                      best_score = score
                      best_params = current_params
      return best_params