wondering if anyone can help me. My class project is to make a program to find the end of a 10x10 maze of 1's(walls) and 0's(path). We need to use a stack and I leave a trail of 2's so each at each choice I just have to search for a 0 or pop. I'm having difficulty with some part of popping the stack. Here's a snippet of some of the code.
case 3:
maze.push(coor);
row = row - 1;
coor.setR(row);
break;
case 4:
JOptionPane.showMessageDialog(null, coor.getR() +" "+ coor.getC());
coor = maze.pop();
row = coor.getR();
col = coor.getC();
JOptionPane.showMessageDialog(null, coor.getR()+" "+coor.getC());
break;
Coor is a class that just stores int row and int column
The program keeps popping untill the stack becomes empty but the OptionPane I set up to test shows the same row/column after every single pop.
Anyone know where my problem is?

