C++ || Easy
\n# Code\n\nclass Solution {\npublic:\n    int minimizeSum(vector<int>& nums) {\n\n        sort(nums.begin(), nums.end());\n        int n= nums.size();\n       
\n# Code\n```\nclass Solution {\npublic:\n    int minimizeSum(vector<int>& nums) {\n\n        sort(nums.begin(), nums.end());\n        int n= nums.size();\n        \n        int val  = min  (abs(nums[0] - nums[n-3]) , min( abs(nums[n-2]-nums[1]), abs(nums[2] - nums[n-1] ) ) );\n        return  val;\n    }\n};\n```
['C++']