2-D array doubt

https://ide.codingblocks.com/#/s/20066

Above is the code link.
How do I pass a 2-D array getting
“array bound is not an integer constant before ‘]’ token int minCostPathGrid(int a[m][n], int m,int n)”
this error, what does it mean.

https://ide.codingblocks.com/#/s/20069
however, this worked.
Does this mean we can’t pass 2-D array as done in the code above ?