Skip to content

Commit 35b6f16

Browse files
authored
Merge pull request #1998 from ljh981009/main
[ljh981009] WEEK 01 solutions
2 parents 2eb3c90 + b2a6cb9 commit 35b6f16

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

contains-duplicate/ljh981009.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -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

Comments
 (0)