CpSc 210, Section 1
                             Assignment 3 
                             June 5, 2000 


Due: Wednesday, June 13 by 11:59 p.m. (This is an extension.)

Assignment:  Implement an Ngon class.


Total point value of assignment:  100 points
Not accepted late.

This assignment is to be done INDIVIDUALLY.


Create a file, Ngon.java, which will contain assignment. Ngon.java will contain a main method, all methods in the Drawable Interface (page 228), and the additional methods toString() and equals.

Model your Ngon class on the Triangle class on pages 229 - 233. Remember that the Triangle fillOn method does not work correctly. The Ngon method should have the following constructors:
          public Ngon ( int n )
          // constructs a regular Ngon of n sides inscribed in a circle
          // of radius 100 with center at (100,100).

          public Ngon ( Pt [ ] vertices ) 
          // constructs a copy of the Ngon with given vertices

          public Ngon ( Ngon other ) // copy constructor
          // constructs a copy of Ngon other

Your main method should contain a test program which tests all methods. In addition, at some point in the test program, all code should have been tested. Ngon.java may contain any additional methods that would be helpful. For example, you might write a method to print out "CPSC 210", your name, the assignment number, and a brief description of the assignment.

Other requirements: The first operation of your main program must be to print "CPSC 210", your name, the assignment number, and a brief description of the assignment.

Follow the style standards to be found on your instructor's web page for CPSC 210. Submit your program using the handin command. There is a link to the handin description on the CPSC 210 lab page (www.cs.clemson.edu/~lab210).
Grading rubric:

	In the opinion of the instructor the program is an honest attempt
	to complete the assignment as described  5 pt.

	The program compiles without error.  10 pts.

	If the two previous requirements are not substantially met, no further 
	points will be awarded.

	Correctness, documentation, style, and quality of test program.  85 pts.
	Points will be subtracted for failure to follow style standards.

	When testing classes, when a method fails and execution terminates,
	no further testing will be done by the grader.  Thus, if the first method 
	tested after the constructor causes the test program to fail, no other
	methods will be tested and your score on the assignment will be very low.

	Therefore, you are advised that the following are the first three
	methods that will be tested:

		the constructor with the single parameter n
		the copy constructor
		the constructor which receives an array as parameter

	After these, the methods will be tested in the order in which they
	appear in the Drawable Interface on page 228, except that fillOn
	will be tested last.   

	If you are in doubt what a method should do, check what the class
	Rect does with the given method.  Remember that Bailey's code for
	fillOn in the Triangle class does not work.