Your code Implementation is wrong

Hi Coding Block,
I was watching video “Max Sum Submatrix In Row And Col”.
The code which you had implemented is wrong.
this is your code go to this link:

see line no. 49 and 26
for(int j = 0; j < n; j++)

here you have written j < n;
this is wrong.

It should be j < m;

I am correct the code. please see this link
(https://ide.codingblocks.com/s/578703) and match with your code .

Sir, you had done same mistake in previous problem(“Submatrix Sum Query”).

Thank in advance
Deepanjali Kumari

Hi Deepanjali… Thanks for pointing out the error. will surely pass on it to the team

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.