array of integer in java code example Example: arrays in java int[] intArray = new int[20]; String[] cars = {"Volvo", "BMW", "Ford", "Mazda"};