package Lect28Debugging; import java.util.*; class Day { private ArrayList appointments; private int dayNumber; private String name; public Day(String theName, int theNumber) { name = theName; dayNumber = theNumber; appointments = new ArrayList(); } public void addAppointment(String description) { appointments.add(description); } public int getDayNumber() { return dayNumber; } public String getName() { return name; } public boolean anyAppointments() { if (appointments.size() != 0) { return true; } else { return false; } } public String toString() { String result=name + "(" + dayNumber + ")\n"; String[] allAppointments = new String[appointments.size()]; appointments.toArray(allAppointments); for (int i=0; i