

Study with the several resources on Docsity
Earn points by helping other students or get them with a premium plan
This page cannot be seen from the preview
Don't miss anything!


CMSC131 Fall 2004 Quiz #7, Duration 25 Minutes
First Name: Last Name: Student Id: Section time (10am/11am): TAs:
Problem Description
A class called WaitList represents a set of students waiting to get into a course. The class relies on a Student class defined as follows:
/* YOU MAY NOT MODIFY THIS CLASS */ public class Student { private String name; private int id;
public Student(String sname, int sid) { name = sname; id = sid; }
public Student(Student student) { name = new String(student.name); id = student.id; }
public int getId() { return id; }
public String toString() { return name + " " + id; } }
WRITE YOUR IMPLEMENTATION ON THE NEXT PAGE