CIS 435 DL, Spring 2004
Midterm Exam
Prof. J. Calvin
Print Name (last name rst): This exam consists of 7 pages, numbered 1 through 7. Before starting to work, make sure that you have all 7 pages. Ther
CIS 435, Spring 2002, Jim Calvin Homework #10 Solutions
16.2-3 Suppose we have n items with weights w1 w2 wn and values v1 v2 vn . The optimal algorithm is: take items 1, 2, . . . , k where k is the f
CIS 435, Fall 2000, Jim Calvin Homework #9 Solutions
17.2-3. Suppose we have n items with weights w1 w2 wn and values v1 v2 vn . The optimal algorithm is: take items 1, 2, . . . , k where k is the fir
CIS 435, Spring 1999, Jim Calvin Homework 7 and 8 Solutions
so we have n activities and so 2n events. Sort the events by increasing time if on activity ends at the same time as another begins, the end
CIS 435, Spring 2002
First Midterm Exam
Prof. J. Calvin
Print Name (last name first): Do not open this exam until instructed to do so. The exam consists of 5 pages, numbered 1 through 5. Before starti
CIS 435, Fall 2001, Jim Calvin Homework #4 Solutions
6.3-3 (Solution in notes.) 6.4-3 If all the elements are equal, heapsort takes (n) time. Assume that the elements are distinct. Then if the array i
CIS 435, Fall 2001
First Midterm Exam
Prof. Jim Calvin
Print Name (last name first):
Do not open this exam until instructed to do so. The exam consists of 6 pages, numbered 1 through 6. Before startin
So far in the course we have seen many problems that have polynomialtime solutions that is, on a problem instance of size n, the running time T (n) = O(n ) for some k, with k typically small. For exam
CIS 435, Spring 1999, Jim Calvin Induction
The principle of induction is simple, applying it takes a bit of practice. This note is to give you some practice. Recall the principle: If a property of the
CIS 435, Spring 2000, Jim Calvin Induction
The principle of induction is simple, applying it takes a bit of practice. This note is to give you some practice. Recall the principle: If a property of the
CIS 435 DL, Fall 2001, Jim Calvin Homework #12 Solutions 34.1-4. The dynamic programming solution ran in time O(nW ), which at first glance appears to be polynomial time. However, it requires lg(W ) b