# # 代码中的类名、方法名、参数名已经指定,请勿修改,直接返回方法规定的值即可 # # # @param numbers int整型一维数组 # @param target int整型 # @return int整型一维数组 # class Solution: def twoSum(self , numbers: List[int], target: int) -> List[int]: # write code here map = {} for i in range(len(numbers)): if target - numbers[i] in map.keys(): return [map[target - numbers[i]] + 1, i + 1] map[numbers[i]] = i