void main() {
    Map<String, Integer> scores = new LinkedHashMap<>();
    scores.put("Ada", 88);
    scores.put("Grace", 92);
    scores.put("Alan", 45);

    int total = 0;
    for (int score : scores.values()) {
        total += score;
    }

    IO.println(total);
    IO.println((double) total / scores.size());
}

// From Groundwork, chapter 9 (ch09-maps-and-sets), box 7.
// This example is from Groundwork, licensed CC BY-NC-SA 4.0.
// Run with: java ch09_07.java
