HW for the Java class