✅ || Custom comparator || C++
Solution\n\n#### Logic\n\nConvert to String and do as question says\n\n\ncpp\nclass Solution {\npublic:\n    static bool my_sort(pair<int, int> &a, pair<int, in
## Solution\n\n#### Logic\n\nConvert to String and do as question says\n\n\n```cpp\nclass Solution {\npublic:\n    static bool my_sort(pair<int, int> &a, pair<int, int> &b) {\n        if (a.first < b.first) {\n            return true;\n        }\n        return false;\n    }\n    vector<int> sortJumbled(vector<int>& mapping, vector<int>& nums) {\n        vector<pair<int, int>> my_nums;\n        vector<int> sol;\n        \n        for (auto num : nums) {\n            string s = to_string(num);\n            int old_num = num;\n            string new_num = "";\n            for (int i = 0; i < s.size(); i++) {\n                new_num += to_string(mapping[s[i] - \'0\']);\n            }\n            my_nums.push_back(make_pair(stoi(new_num), old_num));\n        }\n        \n        sort(my_nums.begin(), my_nums.end(), my_sort);\n        for (auto num : my_nums) {\n            sol.push_back(num.second);\n        }\n        \n        return sol;\n    }\n};\n```\n\n __Check out all [my](https://leetcode.com/siddp6/) recent solutions [here](https://github.com/sidd6p/LeetCode)__\n\n \n __Feel Free to Ask Doubts\nAnd Please Share Some Suggestions\nHAPPY CODING :)__\n\n</p>\n\n
['C']