22C:31 Algorithms Programming Project: Additional Instructions

  1. As discussed in class, the format for the input file to your programming project is:
    x1	y1
    x2	y2
    x3	y3
    The coordinates (x1, y1) specify the first point. Similarly each of the other lines contain coordinates for a point in the input. The x-coordinate and the y-coordinate are separated by white space. For the regular part of the project, you may assume that the points are specified in counter-clockwise order around the convex polygon that they define. For the first extra credit part of the project, you cannot assume any ordering on the input points, but you may assume that they do form the vertices of a convex polygon.

  2. Your program does not have to do any error checking. It may assume that the coordinates are in the range 0 through 400. As mentioned in the project, it may assume that no three points are collinear. There might be other assumptions that you make; make sure to mention these in your documentation.

  3. Your program, when executed, may or may not prompt the user for the name of an input file. If your program does not prompt the user for the name of an input file, make sure that your program is hardcoded to read from a file called points.txt. We will create a text file with this name for testing your program.

  4. It is possible that your program may run fine on some inputs, but not on others. If you want to to demonstrate the correct running of your porgram, you should include files named points1.txt, points2.txt, etc., in your submission. Also, mention this in the documentation that you submit. We will execute your program on the point sets you provide before testing it on our point sets.