Sort | Minimum Gap | DIRECT
Code\n\nclass Solution {\npublic:\n    int findValueOfPartition(vector<int>& nums) {\n        int mini=INT_MAX,n=nums.size();\n        sort(nums.begin(),nums.en
# Code\n```\nclass Solution {\npublic:\n    int findValueOfPartition(vector<int>& nums) {\n        int mini=INT_MAX,n=nums.size();\n        sort(nums.begin(),nums.end());\n        for(int i=1;i<n;i++){\n            mini=min(mini,abs(nums[i]-nums[i-1]));\n        }\n        return mini;        \n    }\n};\n```
['C++']