C++|| very easy binary-search solution|| k subset partition prob
\nclass Solution {\npublic:\n    bool check(vector<int>&nums,vector<int>&vec,int step,int val)\n    {\n        if(step>=nums.size()) return true;\n        int c
```\nclass Solution {\npublic:\n    bool check(vector<int>&nums,vector<int>&vec,int step,int val)\n    {\n        if(step>=nums.size()) return true;\n        int cur=nums[step];\n        for(int i=0;i<vec.size();i++)\n        {\n            if(vec[i]+cur<=val)\n            {\n                vec[i]+=cur;\n                if(check(nums,vec,step+1,val)) return true;\n                vec[i]-=cur;\n            }\n            if(vec[i]==0) break;\n        }\n        return false;\n    }\n    int minSessions(vector<int>& tasks, int sessionTime) {\n        \n        int l=1,r=tasks.size();\n        while(l<r)\n        {\n            int mid=(l+r)/2;\n            vector<int>vec(mid,0);\n            if(check(tasks,vec,0,sessionTime))\n            {\n                r=mid;\n            }\n            else\n                l=mid+1;\n        }\n        return l;\n    }\n};\n```
['Backtracking', 'Binary Search Tree']