C++ || DP solution  || Tabulation method
Intuition\nMatrix Chain Multiplication [M C M] . DP solution using tabulation method.\n\n\n\n# Complexity\n- Time complexity:O(n^3)\n Add your time complexity h
# Intuition\nMatrix Chain Multiplication [M C M] . DP solution using tabulation method.\n\n\n\n# Complexity\n- Time complexity:O(n^3)\n<!-- Add your time complexity here, e.g. $$O(n)$$ -->\n\n- Space complexity:O(n^2)\n<!-- Add your space complexity here, e.g. $$O(n)$$ -->\n\n\n# Code\n```\n#include<bits/stdc++.h>\nusing namespace std ;\nclass Solution {\npublic:\n\n \nint solveTab(vector<int> &values){\n    int n = values.size();\n    vector<vector<int>> dp(n, vector<int> (n,0)) ;\n\n    for(int i = n-1 ; i>=0 ; i--){\n        for(int j = i+2 ; j<n ; j++){\n            int ans =INT_MAX;\n\n            for(int k = i+1;k<j ;k++){\n                ans = min(ans ,values[i]*values[j]*values[k] + dp[i][k] + dp[k][j] ) ;\n            }\n            dp[i][j] = ans ;\n            \n        }   \n    }\n    return dp[0][n-1];\n\n}\n\nint minScoreTriangulation(vector<int> &values)\n{\n    return solveTab(values);\n}\n\n};\n```
['Dynamic Programming', 'Matrix', 'C++']