⚡️ Tryprepforge
Backend Engineer Senior programming

Implement a function that takes a string as input and returns all unique permutations of the string sorted in lexicographical order. ### Constraints: - The input string will contain lowercase letters only and will have at most length 9. ### Examples: 1. Input: 'abb' Output: ['abb', 'bab', 'bba'] 2. Input: 'a' Output: ['a']

Suggested Answer

Practice More Questions Like This

Generate unlimited interview questions with structured answers, code runner, and AI-powered walkthroughs.

No credit card required

More Backend Engineer Interview Prep

Link copied to clipboard