if statements checking if it's a "white square" or "black square" specifically; the math handles the alternation naturally.public class CheckerboardV2 public static void main(String[] args) Scanner input = new Scanner(System.in);
Some "V2" extensions require non-square patterns. The parity rule still applies, but you might need to offset odd rows. Example: staggered rows like a brick wall.