Segmentation fault

Code is not running. Can you please tell me what i am missing.
link to my code = https://ide.codingblocks.com/s/236081

hello @pulkit_pandey09
you have not handled some corner cases in ur code.

a) if(j>=m) return false;

b) if(i>=n) return false;

not able to pass test cases. link to my code- https://ide.codingblocks.com/s/236081

bro u were violating social distancing :stuck_out_tongue_winking_eye:.
add space between two elements it will pass.
image