class Solution { public: string trans(string s, int n) { stack<string> stack; string str = ""; ...