Leetcode 2904. Shortest and Lexicographically Smallest Beautiful String | Hello Interview