input: Write a function to take a list of objects where each object contains an ID and a list of inputs, and return a list of objects where each object contains the ID and the sum of the inputs. The function should be named `calculate_result`.
  assert calculate_result([{"id": 1, "inputs": [1,2,3]}, {"id": 2, "inputs": [2,3,4]}])==\
  [{'id': 1, 'result': 6}, {'id': 2, 'result': 9}]
  assert calculate_result([{"id": 3, "inputs": [4,5,6]}, {"id": 4, "inputs": [7,8,9]}])==\
  [{'id': 3, 'result': 15}, {'id': 4, 'result': 24}]
  assert calculate_result([])==[]
  assert calculate_result([{"id": 5, "inputs": [1]}, {"id": 6, "inputs": [2]}])==\
  [{'id': 5, 'result': 1}, {'id': 6, 'result': 2}]
output: def calculate_result(objects):
      return [{'id': obj['id'], 'result': sum(obj['inputs'])} for obj in objects]