UMBC CMSC441, Design & Analysis of Algorithms, Fall 1999, Section 0101

Homework Assignments 5-6

The following homework problems have been assigned for Section 0101 of CMSC441.

Homework 5, Due Thursday October 14

  1. Exercise 10.3-8, page 192.

  2. Exercise 10.3-9, page 192.

    The optimal location is at the median of the y-coordinates of the oil wells. Prove why.

  3. Given a (not necessarily sorted) sequence S = {k1, k2, ..., kn} of n arbitrary numbers. Consider the collection C of n2 numbers of the form: min{ki, kj}, for 1 <= i, j <= n. Present an O(n)-time and O(n)-space algorithm to find the median of C.

Homework 6, Due Thursday October 21

  1. Exercise 14.2-5, page 267.

  2. Problem 14-2, pages 278-279.

  3. Given an array A of n elements, and an array B of m elements, how would you find A intersect B? Report your running time in terms of n and m.


Last Modified: 6 Oct 1999 16:36:30 EDT by Richard Chang
to Fall 1999 CMSC 441 Section Homepage