Remove Duplicate Letters题目不理解,求大神
leetcode吧
全部回复
仅看楼主
level 1
studiaholic 楼主
原题链接https://leetcode.com/problems/remove-duplicate-letters/
原题为:
Given a string which contains only lowercase letters, remove duplicate letters so that every letter appear once and only once. You must make sure your result is the smallest in lexicographical order among all possible results.
里面的the smallest in lexicographical order among all possible results.是什么意思
2016年03月08日 12点03分 1
level 13
假设只需要remove duplicate
对cbacdcbc,结果有可能是acdb,也可以是adcb,还有可能是其他,这里面字典顺序最小的是acdb
(注意abcd不可能出现)
2016年03月09日 03点03分 2
多谢
2016年03月09日 08点03分
1