Can someone help me with this question?
Given a list of string, and an input string, return the next string in the list in lexical order. What's the time complexity and space complexity.