CSE 1311 - Section 2 - Assignments - Assignment 8

Due date: Wednesday, April 07, 2010, 11:55pm.


Task 1 (50 points)

Complete the code already written in file task1.cpp, that behaves as follows: The Euclidean distance between points (x1, y1) and (x2, y2) is defined as:

sqrt((x1-x2)*(x1-x2) + (y1-y2)*(y1-y2))

For example: the Euclidean distance between point (1.2,2.5) and point (3.1,5.6) is 3.6359.

Note that:


Task 2 (50 points)

Complete the code already written in file task2.cpp, that behaves as follows:

Note that:


How to submit

Submisions are only accepted via WebCT. The submission should include your C or C++ source files, and answers.doc. Do not submit entire project directories, or anything else except for the .c and .cpp files and the answers.doc file.

Your answers.doc file should be a single Microsoft Word file that includes:

Make sure that your answers.doc file is easy to parse, and that it is easy for us to figure out which part corresponds to which task. Feel free to use headings such as "start of copy of task1.c".

We try to automate the grading process as much as possible. Not complying precisely with instructions causes a significant waste of time during grading, and thus points will be taken off for failure to comply, and/or you may receive a request to resubmit.

Submission checklist