@@ -0,0 +1,1632 @@
+#https://leetcode.com/problems/combination-sum-ii/description/%0Aclass Solution(object):%0A    def combinationSum2(self, candidates, target):%0A        %22%22%22%0A        :type candidates: List%5Bint%5D%0A        :type target: int%0A        :rtype: List%5BList%5Bint%5D%5D%0A        %22%22%22 %0A %0A        self.candidates = candidates%0A        self.size = len(candidates)%0A        self.rtype = %5B%5D %0A        def findsums(valuesum,valuelist, index, target):  %0A            complete = False%0A            if valuesum %3E target:%0A                return%0A            elif valuesum == target:  %0A                if valuelist not in self.rtype:%0A                    self.rtype.append(valuelist)%0A                return%0A            while index %3C self.size:%0A                %0A                if valuesum + self.candidates%5Bindex%5D == target: %0A                    good = valuelist%5B:%5D%0A                    good.append(self.candidates%5Bindex%5D) %0A                    if good not in self.rtype:%0A                        self.rtype.append(good )%0A                        return%0A                elif valuesum + self.candidates%5Bindex%5D %3C target:%0A                    less = valuelist%5B:%5D%0A                    less.append(self.candidates%5Bindex%5D)%0A                    findsums(valuesum + self.candidates%5Bindex%5D,less,index + 1,target)%0A                elif valuesum + self.candidates%5Bindex%5D %3E target: %0A                    great = valuelist%5B:%5D%0A                    return %0A                index += 1%0A        count = 0%0A        self.candidates.sort()%0A        while count %3C self.size :%0A            findsums(self.candidates%5Bcount%5D,%5Bself.candidates%5Bcount%5D%5D,count + 1,target)%0A            count += 1%0A        return self.rtype%0A

Create CombinationSum.py