Coding Standards - CS180 Coding Standards File Names In this course each Java file name should clearly represent what it is and each should have

Info iconThis preview shows pages 1–3. Sign up to view the full content.

View Full Document Right Arrow Icon
CS180 Coding Standards File Names In this course each Java file name should clearly represent what it is and each should have the ``.java'' suffix. Files names must match the class name. For example, Project 1 should be Project1.java. A lab project that determines the payroll of a small company could be Payroll.java (or even something like Lab3.java). Comment Header At the beginning of each Java class there should be a JavaDoc block that contains: The program name, your name, and recitation section. A brief description of the program that describes the method or algorithm used to obtain the solution, the major data structures (if any) in the program, and other general comments including extra features. The date the program was completed. The format to be used is as follows: /** * Program Name * brief description of the program * * @author your name * * @recitation section number and recitation instructor's name * * @date date of creation * * @C_date current date */
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
An example of one such comment is /** * Project 1 -- Video Calculator * This program inputs the total number of minutes, * the number of minutes for commercials, and the * number of minutes for episodes. The program * computes the total number of minutes for videos, * the number of videos, and the number of seconds * left over. * * @author Elwood Blues * * @recitation 03 (Andy Scharlott) * * @date September 14, 2005 * */ Declarations You should use mnemonic names for all identifiers. These are names that have meaning in the problem. The names should suggest the use of the identifier. Variable identifiers should be in all lower-case letters, except for capital
Background image of page 2
Image of page 3
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 02/05/2012 for the course CS 180 taught by Professor Staff during the Fall '08 term at Purdue University-West Lafayette.

Page1 / 7

Coding Standards - CS180 Coding Standards File Names In this course each Java file name should clearly represent what it is and each should have

This preview shows document pages 1 - 3. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online