Explained - Find min upto that cell and take diff
Intuition\n- Need to find the min max, such that min item cell should be towards left and top of the max item cell.\n\n# Approach\n- Keep tracking the smallest 
# Intuition\n- Need to find the min max, such that min item cell should be towards left and top of the max item cell.\n\n# Approach\n- Keep tracking the smallest number till the current cell torards its left and towards its top.\n- Consider the current cell as the max item and take diff. Keep tracking the max diff\n\n# Complexity\n- Time complexity: O(N.N)\n\n- Space complexity: O(1)\n\n# Code\n```\nint maxScore(vector<vector<int>>& grid) {\n    int ans = INT_MIN;\n    for(int i = 0; i < grid.size(); ++i){\n        for(int j = 0; j < grid[0].size(); ++j){\n            int mn = INT_MAX;\n            if(i == 0 && j == 0) continue;\n            if(i != 0) mn = min(mn, grid[i-1][j]);\n            if(j != 0) mn = min(mn, grid[i][j-1]);\n            ans = max(ans, grid[i][j] - mn);\n            grid[i][j] = min(grid[i][j], mn);\n        }\n    }\n    return ans;\n}\n```\n\n\n---\n\n<b>Here is an article of my last interview experience - A Journey to FAANG Company, I recomand you to go through this to know which all resources I have used & how I cracked interview at Amazon:\nhttps://leetcode.com/discuss/interview-experience/3171859/Journey-to-a-FAANG-Company-Amazon-or-SDE2-(L5)-or-Bangalore-or-Oct-2022-Accepted\n\n---
['C++']