S2 icon indicating copy to clipboard operation
S2 copied to clipboard

0216. Combination Sum I I I | LeetCode Cookbook

Open halfrost opened this issue 4 years ago • 3 comments

https://books.halfrost.com/leetcode/ChapterFour/0200~0299/0216.Combination-Sum-III/?code=979c06a1661eddbb8107

halfrost avatar Feb 26 '21 13:02 halfrost

请问一下,为什么进行类似于77题中的剪枝放在这里i <= 9 - (k - len(c)) + 1的时候会爆栈呢……

PanYuHaa avatar Jun 29 '22 02:06 PanYuHaa

@PanYuHaa 我印象是因为这个剪枝条件太弱了。剪的不够多。剪枝效果不好。

halfrost avatar Jun 29 '22 02:06 halfrost

@halfrost 感谢!

PanYuHaa avatar Jun 29 '22 02:06 PanYuHaa