Smalltalk balloon

Homework Submission Requirements


Computer Science II
Object-Oriented Programming


This document outlines the rules you should follow when submitting a homework assignment for grading. These rules will simplify the grader's job by standardizing the form and appearance of submissions. Any of these rules can be overridden by a particular assignment but, if the assignment doesn't say otherwise, follow each of them.

Forms of Submission

When you are asked to submit a set of files, you must submit them in two forms: electronically and hard copy.


Document each file with a header block that includes at least:

Here's an example:

    // FILE:
    // AUTHOR:   Eugene Wallingford --
    // DATE:     01/31/99
    // COMMENT:  Factored out of Budd's Ball class state and paint behavior.
    // MODIFIED: 03/08/99 by Eugene Wallingford
    // CHANGE:   Added a getColor() accessor.

Your block need not look exactly like this, but it should contain the same information.


I do not require you to follow a lot of specific style rules, but I do ask you to follow several basic guidelines to improve the readability of your code.

  1. Indent your code to indicate that one expression is subsidiary to another. For example, say this:
        for (int i = 0; i < 10; i++)
            System.out.println( i );

    instead of this:

        for (int i = 0; i < 10; i++)
        System.out.println( i );

  2. Indent consistently. Indent all for statement bodies the same number of characters. Indent all if statement bodies the same number of characters. Be consistent within a single file and across multiple files. Adopt some conventions that you like, and stick with them.

  3. Use names that say what they name. For example, numScores is a better name than n, and numberOfScores is better yet. By convention, we use single-letter variable names in only one context: as (loop) index variables.

  4. Use uppercase characters to begin the names of classes. Use lowercase characters to begin the names of methods and instances. Use embedded uppercase characters in all names as a way combine mulitiple words in the same name, such as in numberOfScores.

Eugene Wallingford ==== ==== January 27, 2004