dont overthink
Approachsimple simulation of problem statementCode
# Approach
<!-- Describe your approach to solving the problem. -->
simple simulation of problem statement
# Code
```cpp []
class Solution {
public:
    int minimumPairRemoval(vector<int>& nums) 
    {
        int ans=0;
        while(true)
        {
            //check if array is non decreasing
            int n=nums.size();
            bool flag=false;
            for(int i=0;i<n-1;i++)
            {
                if(nums[i]>nums[i+1])
                {
                    flag=true;
                    break;
                }
            }
            if(!flag) break;
            //find the minimum and simulate
            int sum=INT_MAX,index;
            for(int i=0;i<n-1;i++)
            {
                if(nums[i]+nums[i+1] < sum)
                {
                    sum=nums[i]+nums[i+1];
                    index=i;
                }
            }
            nums.erase(nums.begin()+index+1);
            nums[index]=sum;
            ans++;
        }
        return ans;   
    }
};
```
['C++']