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 0fc7ec8 commit b2a6cb9Copy full SHA for b2a6cb9
contains-duplicate/ljh981009.ts
@@ -0,0 +1,4 @@
1
+function containsDuplicate(nums: number[]): boolean {
2
+ const result = new Set(nums);
3
+ return result.size !== nums.length;
4
+}
0 commit comments