Hello everyone
I have a task of changing values in an int[][], for example if I input 1 it is changed to 0 and vice versa. So far I tried the following for a hundred times amending the xs and ys but with no happy ending.
public void reverseOrder(int x , int y) {
if (position[x][y] == 1) {
position[y][x] = 0;
} else if (position[x][y] == 0) {
position[y][x] = 1;
}
}
Some advice is much appreciated.
Johan