C++ || DP + Bitmasking
class Solution {\npublic:\n    \n    vector> dp;\n    \n    int fun(int curTime,vector& arr,int t,int mask){\n        if(mask == (1 << arr.size())-1)\n         
class Solution {\npublic:\n    \n    vector<vector<int>> dp;\n    \n    int fun(int curTime,vector<int>& arr,int t,int mask){\n        if(mask == (1 << arr.size())-1)\n            return 0;\n        \n        if(dp[curTime][mask] != -1)\n            return dp[curTime][mask];\n        \n        \n        int ans = 15;\n        \n        for(int i = 0; i < arr.size(); i++){\n            \n            if((mask & (1<<i)) == 0){\n                mask = mask ^ (1 << i);\n                \n                if(curTime + arr[i] <= t)\n                    ans = min(ans , fun(curTime + arr[i], arr, t , mask));\n                else\n                    ans = min(ans , 1+fun(arr[i], arr, t , mask));\n                \n                mask = mask ^ (1 << i);\n            }\n        }\n        \n        return dp[curTime][mask] = ans;\n    }\n    int minSessions(vector<int>& arr, int t) {\n        int n = arr.size();\n        \n        dp = vector<vector<int>> (t+1,vector<int>( (1<<arr.size())-1 , -1));\n        int mask = 0;\n        return 1+fun(0,arr,t,mask);\n    }\n};
['Dynamic Programming', 'Bit Manipulation', 'C', 'C++']