int[] intArray = new int[20]; for (int i = 0; i < intArray.length; i++) { intArray[i] = i + 1; }