simplest sol ever
int minimumSum(int num) {\n\n        int arr[4];\n        int i=0;\n        while(num!=0){\n            arr[i]=num%10;\n            num=num/10;\n            i++
int minimumSum(int num) {\n\n        int arr[4];\n        int i=0;\n        while(num!=0){\n            arr[i]=num%10;\n            num=num/10;\n            i++;\n        }\n        sort(arr,arr+4);\n        int r=arr[0]*10+arr[2];\n        int s=arr[1]*10+arr[3];\n        return r+s;\n    }
[]