my code is https://ide.codingblocks.com/s/173389.
according to the video lecture I would have got the correct answer but I am not. Please see to it.
I am not able to get the correct answer
@adarsh_anand Remove +1 from li and lj in line 19 and 21.
According to the brute force solution as mentioned in the video, 1 x 1 matrix is not included.
To include that you just have to modify the loops for bottom right coordinates. Just begin these loops from top left coordinate values.
that means the pseudo code shown in video was wrong?
@adarsh_anand Not wrong but according to that pseudo code 1 x 1 matrix was not included. So your answer was coming different.
1 Like