https://leetcode.com/problems/find-all-duplicates-in-an-array/ 一列数,1 ≤ a[i] ≤ n (n = size of array),有的出现一次有的出现两次,输出出现两次的数. Example: Input: [4,3,2,7,8,2,3,1] Output: [2,3] 耿直的你大概会写出如下代码 class Solution(object): def findDuplicates(self, nums): myset=set…