Accepted: C++ 0ms
Approach:\nAs it is already mentioned that we have only 4 digits so we can use 4 size vector to store the digits.\n- Store the digits in vector.\n- Sort the vec
**Approach:**\nAs it is already mentioned that we have only 4 digits so we can use 4 size vector to store the digits.\n- Store the digits in vector.\n- Sort the vector.\n- To keep the number small, start with the number with lowest digits. So lets create first numbers first digit with 0th element of the sorted vector and create first digit of the second number with the 1st index digit of the vector.\n- sum of the created numbers is the answer.\n```\nint minimumSum(int num) {\n        vector<int> digit(4, 0);\n        for(int x=0; x < 4; x++) {\n            digit[x] = num%10;\n            num = num/10;\n        }\n        sort(digit.begin(), digit.end());\n        int f = digit[0] * 10 + digit[2];\n        int s = digit[1] * 10 + digit[3];\n        \n        return f + s;\n    }\n```
['C']