Code Check List

This check list should help ensure you have written and formatted your code properly. It will be updated throughout the semester, so be sure to check back from time-to-time. Until you are comfortable with these guidelines, be sure to compare your code against these guidelines before you submit it. In a very short time, these guidelines will become second nature and you'll find you are following them automatically.

0.0 All work should be pledged

This is a school requirement. Just write the word pledged on your paper.

0.1 Write on you code how long it took you to write the code.

Ideally you will include the amount of time you spent planning, the amount of time you spend coding, and the amount of time you spent debugging, but for simple problems a lump sum is okay.

This will not affect your grade, but it will help me to pick up on problems you or the class may be having and will help me adjust the pace of the class so you don't become either overstressed or bored.

1. Required Comments for Code

At the beginning of each file:
The file name, your name, & date
General description of code in file
Any appropriate citations for sources!

At the beginning of each function in a file:
Description of the function
Inputs to the function
Outputs from the function

2. Use reasonable variable names

For common math formulas, these can be single letters (A = Pi * r ** 2). But most of the time you should use meaningful English words that convey how the variables are being used. When in doubt, be verbose.

3. Make appropriate use of white space in your code.

Skip lines between functions and leave spaces in expressions to improve readability.

4. Be sure to provide meaningful prompts when reading data interactively.

5. When printing information, be sure to carefully label and format that information.

6. Please use a monospace font like courier when printing your work.