Skip to content

Commit f3d0259

Browse files
committed
feat: Upload contains-duplicate solution (typescript)
1 parent 8901b1d commit f3d0259

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

contains-duplicate/mike2ox.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 set = new Set<number>(nums);
3+
return set.size !== nums.length;
4+
}

0 commit comments

Comments
 (0)