I want to only pass columns of a 2 d array in a method call. I know how to pass 2 d row by row and that is
Check(a[i],9); taken in mind that a is defined as a 2 d array.
However I don’t know how to do that row by row… not when doing this gives error
Check(a[i][],9);
Thanks
You cannot access a ‘column’ in a 2d array in this way, at least not in Java. You would need to manually iterate the rows and select the column value you wanted.