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