Computer Science 211 |
You should come to our meeting with a proposed design for your CoinStrip class. These designs may be handwritten or typed. They will be checked at the start of lab and will constitute a small part of the grade for this week's lab.
During today's meeting, you will learn how to use the Java environment on the Macs in Kendade 307, both at the Unix command line (using Emacs to edit, if you wish) and in the Eclipse integrated development environment (IDE), brush up on your Java, and get started on the lab program.
You can find information about how to do many of these tasks on the page of information about Java and Unix on the Kendade 307 Macs, linked from the course home page.
ls cd cp mv rm mkdir pwd man chmod cat more grep head tail ln find rmdir wc diff tar
C-x C-s C-x C-c C-x C-f C-x C-w C-g C-a C-e C-d C-_ C-v M-v C-s C-r M-%
Learn these commands - you will use them often. Hints can be found in the Unix and Emacs web pages on the course website.
Your task for the lab this week is to write the Silver Dollar Game at the end of Chapter 3 in Bailey.
Write your program in a file named CoinStrip.java. Include a main method in this class to play the game. This method should create an instance of CoinStrip, as is done in the PocketChange class example.
When you have finished the program, turn in CoinStrip.java by emailing it to jteresco AT mtholyoke.edu as an attachment.
Also, answer the thought questions at the end of the lab. Put your answers in the file lab1.txt and submit that file as an email attachment as well to jteresco AT mtholyoke.edu.
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 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. You should also include a justification of your choice of internal data structure as a comment where you declare that structure in your program.
Grading Breakdown | |
Pre-lab design | 3 points |
Program design | 3 points |
Program style | 3 points |
Program documentation | 5 points |
Program correctess | 10 points |
Thought questions | 6 points |
The program design grade will be based on the appropriateness of your choice of internal data structures and methods provided to play the game. 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. The program correctness grade is based on how well your program meets the functionality requirements.