What is mistake in this code just 1 test case fail in both

https://ide.codingblocks.com/s/249117 // magical park
https://ide.codingblocks.com/s/249118 //spiral print

@rohitkandpal683 in magical park while scanning array you have taken m as row but you have taken row input in n.
in spiral print run your while loop till startrow<=endrow and same for column.