Code is not passing the test cases

i tried it with the sample input it is coming out 100% correct . i dont know what is with the code.

hello @ashishxmathew
image

first read m and then n