摘要:
回溯的方法 class Solution: def permutation(self, s: str) -> List[str]: ans = set() def backtrace(path,tmp): if path=="": ans.add(tmp) return for i in range 阅读全文
posted @ 2021-01-19 16:21
WangSJiNa
阅读(30)
评论(0)
推荐(0)
摘要:
class Solution: def longestConsecutive(self, nums: List[int]) -> int: cur_len = 0 nums = set(nums) ans = 0 for item in nums: if item-1 not in nums: cu 阅读全文
posted @ 2021-01-19 13:32
WangSJiNa
阅读(48)
评论(0)
推荐(0)

浙公网安备 33010602011771号