View this PageEdit this PageAttachments to this PageHistory of this PageHomeRecent ChangesSearch the SwikiHelp Guide
Hotspots: Admin Pages | Turn-in Site |
Current Links: Case Final Project Summer 2007

Sum2002 Midterm Review: Analyze Student/Classroom Code

Edit Sum2002 Midterm Review: Analyze Student/Classroom Code here.

a. (7 points) What would you say is the relationship between Student objects and the Classroom object is? Why?

Classroom has zero or more Students (a has-a relationship versus an
is-a relationship).

b. (10 points) What attributes and services do you think that the Student and Classroom objects have, based on what you see in the above code?

the Classroom has a name, and an unordered collection of students.
each Student has a name, section, and student number. this is all i
can say given the code segment.


What about operations (methods?)

Classroom has the method addStudent. both probably have their set of accessors. alan fay

Link to this Page