package chapter20230809;
import java.util.*;
public class test13 {
public static void main(String[] args) {
int[] numbers = new int[10];
for(int i = 0; i < numbers.length; i++) {
numbers[i] = i + 1;
}
System.out.print("main() : ");
for(int i = 0; i < numbers.length; i++) {
System.out.print(numbers[i]);
if ( i < numbers.length -1) {
System.out.print(", ");
}
}
System.out.println();
printOdd(numbers);
}
public static void printOdd(int[] numbers) {
System.out.print("printOdd() : ");
for(int i = 0; i < numbers.length; i++) {
if(numbers[i]%2 == 0) {
System.out.print(numbers[i]);
}
if ( i < numbers.length -1) {
System.out.print(", ");
}
}
}
}