Which of the following is the correct syntax for declaring an array of integers in Java?
a) int[] myArray = {1, 2, 3, 4, 5};
b) int myArray[] = {1, 2, 3, 4, 5};
c) int[] myArray = new int[5];
d) int myArray[5] = {1, 2, 3, 4, 5};
Answer: a) int[] myArray = {1, 2, 3, 4, 5};
Explanation: The syntax for declaring an array of integers in Java is to use the int[] keyword followed by the name of the array, an equal sign, and a list of values enclosed in curly braces.