class Solution(object):
def findNumbersWithSum(self, nums, target):
“”“
:type nums: List[int]
:type target: int
:rtype: List[int]
“”“
i1=[]
i2=[]
for j in nums:
if target-j in nums:
i1.append(target-j)
i1.append(j)
break
else:
i2.append(j)
return i1