Given the integer array hourlyMiles with the size of NUM_IN, write a for loop to output the integers in the first half of hourlyMiles. Separate the integers with an asterisk surrounded by spaces (" * ").
Ex: If the input is 79 103 81 95 112 69 71 43, then the output is:
79 * 103 * 81 * 95
import java.util.Scanner;
public class MileRecord {
public static void main(String[] args) {
Scanner scnr = new Scanner(System.in);
final int NUM_IN = 8;
int[] hourlyMiles = new int[NUM_IN];
int i;
for (i = 0; i < hourlyMiles.length; ++i) {
hourlyMiles[i] = scnr.nextInt();
}
for (/* Your code goes here */) {
/* Your code goes here */
}
System.out.println();
}
}