Instructor: Phill Conrad
TAs: Esra Kucukoguz, Yiming Li, Murali Yeleswarapu
Primary TA for this lab: Esra Kucukoguz
Grader for this lab: Yiming Li
You may choose to work individual, or in pairs on this lab—it is your choice.
You are permited to work in the same pairs you used for lab05/lab06, but it is not required.
Please indicate in your submission in the @author Javadoc comment for each file whether you worked individually or as a pair. For pairs, be sure both names are listed.
If you work individually, you may not collaborate or share code with anyone. Please seek help only from the TAs or the instructor.
If you work in pairs, please follow the usual pair programing practices—work at a single workstation, take turns being the driver and the navigator.
In this case, it is only necessary to make one submission via the "turnin" program—in fact, that is preferred. However, the student that does NOT do the turnin command should please email
and indicate who did the submission for the pair, cc'ing the email address of the student that did submit.
Use that email only when instructed—don't use that email address for regular correspondence with Prof. Conrad.
Open a command line prompt in your ~/cs10/lab07 directory, and use the following command. Notice the space and the period at the end of the line—those are very important!
cp -r /cs/faculty/pconrad/public_html/cs10/09S/labs/lab07/lab07Project .
This command will copy a directory containing several Java files, plus all the extra files for a BlueJ project into your directory.
Other ways to access the code:
Open BlueJ, and use the "Open Project" menu item to navigate to the lab07Project inside your ~/cs10/lab07 directory. This will be similar to what you did last week.
Note:
If you opened up the lab07Project correctly, you'll see In your window, you'll see two Java classes
Please spend some time looking through each of these files—reading them the way you would read a book, from top to bottom. Look at the Javadoc comments for each method, and then read through the method to see how the method is implemented—and indeed, whether the method is implemented yet, or whether it is one you are going to have to implement yourself.
Reading through all of the code rather than just jumping in—will really help you get things done faster in the long run. Plus you will learn more, and be better prepared for the next exam!
You'll see places marked with @@@—those are all the places where you'll need to add code.
Once you've noticed all those things, you are ready to move on to part 2.Find the place in IntArrayMethodsTest where you are asked to add extra test methods. You should add test methods that are similar to the ones that test the min method—five new methods in all.
Note: Look ahead to the grading criteria for this step—so you know how your work will be evaluated. Do this
Make a habit of this at every step in every lab.
Find the stub for the max() method, and implement this method so its tests pass.
Find the @@@ comment in IntArrayMethodsTest where you are supposed to add a method to see if count() works on an empty array. Add this test.
These methods are both stubs—replace them with correct code for these methods.
Find the stub for the max() method, and implement this method so its tests pass.
When you reach this point, check for any other @@@ comments, and be sure you've done everything required—then remove the @@@ symbol (and the rest of the comment if appropriate.) If all tests pass, you are ready to turn in!
Use turnin to submit your entire lab07 directory to lab07@cs10
Points for this lab are distributed as follows. Partial credit may be awarded for each step at the discretion of the TA/Instructor.
Total points: ?
Due Date: We'll accept this assignment up without penalty up until noon, Thursday 05/28.
Submissions turned in after that time are subject to receiving zero credit—they will be graded only they arrive before the TA finishes work on grading the entire "batch" of assignments submitted.
End of lab07