record Student(String name, int grade, int score) {}

void main() {
    ArrayList<Student> students = new ArrayList<>(List.of(
            new Student("Ada", 9, 88),
            new Student("Grace", 10, 92),
            new Student("Alan", 9, 45),
            new Student("Katherine", 11, 95)));

    for (Student student : students) {
        IO.println(student.name() + ": " + student.score());
    }
}

// From Groundwork, chapter 10 (ch10-records), box 7.
// This example is from Groundwork, licensed CC BY-NC-SA 4.0.
// Run with: java ch10_07.java
