public class ScoresAverage { public static void main(String[] args) { double scores[] = { 76.0, 84.5, 92.5, 88.0, 96.0 }; double sum= 0; double average; for (int i = 0; i < scores.length; i ++) { sum += scores[i]; } average = sum / scores.length; System.out.println("The average of the scores is " + average); System.out.println(scores[4] + " is the fourth element in the scores array."); System.out.println("There are " + scores.length + " elements in this array."); } }