To create an array, you specify the type, add square brackets, and use the new keyword with a size:
int[] scores = new int[5];
double[] prices = new double[10];
String[] names = new String[3];
The number inside the brackets sets the array's length. Java fills every slot with a default value. For int and double, the default is . For boolean, it is false. For object types like String, it is null.
You can also place the brackets after the variable name: int scores[]. Both forms compile, but int[] scores is the standard Java convention. Stick with it so your code matches what other Java developers expect.