How to get the smallest in lexicographical order?

后端 未结 6 1790
抹茶落季
抹茶落季 2021-02-05 07:43

I am doing a leetcode exercise

https://leetcode.com/problems/remove-duplicate-letters/

The question is:

# Given a string which contains only lowe         


        
6条回答
  •  名媛妹妹
    2021-02-05 08:37

    There seems to be some misunderstanding; the example states that for the input bcabc, the expected output should be abc, not acdb, which refers to the input cbacdcbc.

提交回复
热议问题