Find Obfuscate Message
Problem Overview
- Select a substring of the message and right-rotate it by 1 exactly once to produce the alphabetically smallest possible message.
- Input: lowercase string message (1 ≤ |message| ≤ 1e5); Output: the obfuscated message.
- Context: Amazon Web Services security module obfuscation requirement.
- From Amazon interviews; a coding interview problem and common interview question.
Example
Unlock to view complete problem details
and practice with sample input/output
Was this article helpful?
View Test Cases & Run Code requires membership
Input Variables
Execution Result:
