返回 s 字典序最小的子序列,该子序列包含 s 的所有不同字符,且只包含一次。
s
注意:该题与 316 https://leetcode.com/problems/remove-duplicate-letters/ 相同
示例 1:
输入:s = "bcabc" 输出:"abc"
s = "bcabc"
:
"abc"
示例 2:
输入:s = "cbacdcbc" 输出:"acdb"
s = "cbacdcbc"
"acdb"
提示:
1 <= s.length <= 1000