Computer Science 211
Data Structures

Mount Holyoke College
Fall 2009


Lab 6: Best Of
Due: 9:00 AM, Friday, November 6, 2009


This week's task is to complete the laboratory in Section 11.4 in the Bailey book - computing the "Best Of" a collection of values by some metric (the compareTo method of Comparable objects).


Getting Started

First, carefully read the lab description in the text and this handout. You will have questions, so be sure to leave plenty of time to discuss this assignment with me and the TAs.

Next, develop a sketch of the BestOf class. What does it extend and/or implement? What instance variables are needed? Do you plan to store its contents in order? Why or why not?

No later than Monday, November 2, please either see me to go over your sketch of this class or email it to me for comment and discussion (for 3 points).


Notes and Guidelines


Submission

When you are finished, please submit the following by email to jteresco AT mtholyoke.edu:


Grading

This lab assignment is graded out of 30 points. As in all labs, you will be graded on design, documentation, style, and correctness. Be sure to document your program with appropriate comments (use Javadoc!), including your name and a general description at the top of the file, a description of each method with pre and postconditions where appropriate. Also use comments and descriptive variable names to clarify sections of the code which may not be clear to someone trying to understand it.

Grading Breakdown

Pre-lab design 3 points
Program design 2 points
Program style 2 points
Program documentation 5 points
BestOf correctness 8 points
BestOf test case 2 points
Syracuse correctness 4 points
Thought questions (1 and 2) 4 points

The program design grade will be based on the design choices you make in the implementation of the BestOf class. The program style grade will be based on code formatting and approriate use of Java naming conventions. The program documentation grade is, of course, based on the comments you provide (including Javadoc and pre and postconditions as appropriate). The program correctness grade is based on how well your program meets the functionality requirements.