Leetcode 1081. Smallest Subsequence of Distinct Characters
Return the lexicographically smallest subsequence of s that contains every distinct character exactly once while preserving relative order. The core challenge is choosing which duplicates to keep or drop to minimize order, typically tackled with a greedy monotonic-stack approach.
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
0
Hello Interview Premium
Your account is free and you can post anonymously if you choose.