Difference between revisions of "CSC231 Final Exam 2010"

From dftwiki3
Jump to: navigation, search
Line 12: Line 12:
 
=Problem #1: Recursive GCD=
 
=Problem #1: Recursive GCD=
  
The following algorithm can be  used to find the greatest common denominator, or ''GCD''.  The GCD of two integers ''m'' and ''n'' is the largest integer that divides both of them with a remainder of 0.  The GCD of 5 and 6 is 1.  The GCD of 10 and 12 is 2.  The GCD of 12 and 20 is 4.
+
The following algorithm can be  used to find the greatest common denominator of two integers, or ''GCD''.  The GCD of two integers ''m'' and ''n'' is the largest integer that divides both of them with a remainder of 0.  The GCD of 5 and 6 is 1.  The GCD of 10 and 12 is 2.  The GCD of 12 and 20 is 4.
  
 
  int gcd(int m, int n) {
 
  int gcd(int m, int n) {

Revision as of 13:31, 12 December 2010

This final exam is take-home. It is open-books, open-notes, and open-Web. It is due a week after it is made available, at 12:00 p.m. on Monday December 20, 2010.

You cannot discuss the details of this exam with anyone except your instructor. The TAs are not allowed to help you out in any way. No question will be answered in person after 12:00 a.m. on 12/13/10. Instead, if you have questions regarding the exam, send them via email to thiebaut@cs.smith.edu, and the question and its answer will be broadcast back to the hole class via email. The exam is given under the rules of the Smith College Honor Code.

Make sure you reference all work/resources you use in your documentation.


...