[Leetcode][python] 15. 3Sum
problem: code: #Input: nums = [-1,0,1,2,-1,-4] # currentArray : -1, 0 # resultArray : [-1, 0, 1] class Solution: def threeSum(self, nums: List[int]) -> List[List[int]]: result = [] def checkExists(num1, num2, num3): for items in result: if (num1 in items) and (num2 in items) and (num3 in items): return True return False #traversal num allZeroFlag = False for i in range(len(nums)): # N for j in r..
2022. 3. 31.