摘要:
首先练习一下python,使用collection的Counter 查看代码 class Solution: def findDuplicate(self, nums: List[int]) -> int: a=Counter(nums) for i in a: if a[i] >= 2: retu 阅读全文
posted @ 2021-12-25 14:46
jozon
阅读(48)
评论(0)
推荐(0)
摘要:
这道题没有什么思路,以为是背包问题,但是一直不会,看了答案是动态规划 看了答案自己码了一遍 int minn一定要记得赋值,int的最值 最大INT_MAX 最小INT_MIN 查看代码 class Solution { public: int numSquares(int n) { vector< 阅读全文
posted @ 2021-12-25 12:56
jozon
阅读(34)
评论(0)
推荐(0)

浙公网安备 33010602011771号