Skip to content
Noteshch-log
AboutSupport
< Back to notes

Browse 2 notes tagged Set.

#Set

LeetCode 217: Contains Duplicate in TypeScript with a Set

Compare a Set's size with the array length, or stop early during one scan, while explaining the Set solution's correctness and expected O(n) complexity.

#LeetCode#Blind 75#TypeScript+5
2026-08-29

LeetCode 128: Longest Consecutive Sequence in TypeScript

Move from sorting to a Set, expand only sequence starts, and give a rigorous expected O(n) analysis for the longest consecutive sequence problem.

#LeetCode#TypeScript#algorithms+3
2026-08-24
Copyright ©2025-2026 hch-log.com. All rights reserved.
Written by Hung-Chih Hsueh ↗ · g3n-data ↗ · All links ↗
Support on Ko-fiAboutPrivacy Policy

Google services settings

Analytics and advertising stay off until you choose.

En中文