Sample Input Error

My code for this question says that the output to sample input will be 11 instead of 13. Is there any error here? Please check.

you have to move row wise and you are doing your work column-vise.Second the program will return whenever the strength is less than minimum strength not when it is less than 0.

Could you please correct the code in that case? As I feel I am traversing in the row wise direction only.

Just swap I and j … Arr[I][j] to arr[j][i]

See, it isn’t working like this. If you know the error, please correct it. Otherwise, close it and I’ll open it again, and seek another TA’s help. I know, what rows and columns are!

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.