We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 8901b1d commit 29a569bCopy full SHA for 29a569b
contains-duplicate/heypaprika.py
@@ -0,0 +1,10 @@
1
+class Solution:
2
+ def containsDuplicate(self, nums: List[int]) -> bool:
3
+ num_dict = {}
4
+ for num in nums:
5
+ if num in num_dict:
6
+ return True
7
+ else:
8
+ num_dict[num] = 1
9
+ return False
10
+
0 commit comments