C++ simple solution using map
\nclass Solution {\npublic:\n    bool isTransformable(string s, string t) {\n        int n = s.length();\n        bool vis[n];\n        memset(vis, 0, sizeof(vi
```\nclass Solution {\npublic:\n    bool isTransformable(string s, string t) {\n        int n = s.length();\n        bool vis[n];\n        memset(vis, 0, sizeof(vis));\n        int j = 0;\n        unordered_map<char, list<int>> data;\n        for(int i=0; i<n; i++){\n            data[s[i]].push_back(i);\n        }\n        while(j < n){\n            if(data.count(t[j]) <= 0){\n                return false;\n            }\n            int pos = data[t[j]].front();\n            data[t[j]].pop_front();\n            if(data[t[j]].size() <= 0){\n                data.erase(t[j]);\n            }\n            char x = t[j];\n            x--;\n            while(x >= \'0\'){\n                if(data.count(x) > 0 && data[x].front() < pos){\n                    return false;\n                }\n                x--;\n            }\n            j++;\n        }\n        for(auto itr=data.begin(); itr!=data.end(); itr++){\n            if(data[itr->first].size() > 0){\n                return false;\n            }\n        }\n        return true;\n    }\n};\n```
['C']