for (int i = 0; i < 5; i++) { System.out.println("Enter an integer."); x = in.nextInt(); if (x % 2 == 0) { even++; System.out.println(x + " is even."); } if (x % 2 == 1) { odd++; System.out.println(x + " is odd."); }