def findDuplicate(self, nums):
for x in nums:
if nums[abs(x)1] < 0:
return abs(x)
else:
nums[abs(x)1] *= 1
Clean Python solution

@woshianderson It is using the number in nums as the index, if a number appears twice, then this nums[number] will be changed to negative number before.
