I have an square grid from a GridLayout(4,4,0,0) for a JPanel, just say 4x4 for a small example
*-*-*-*
*-*-*-*
*-*-*-*
*-*-*-*
Say I want to loop through just the top left corner. For a case,
*-*
*
And for another case, the bottom right corner.
*
*-*
I was thinking of a dynamic loop? For larger size boards.