Chronus interview question

Next lexicographic string with same charcters