0% found this document useful (0 votes)
46 views2 pages

Homework #1 Introduction To Algorithms/Algorithms 1 600.363/463 Spring 2015

This document provides instructions for Homework #1 for an algorithms course. It is due on February 3rd by 5pm and late submissions will not be accepted. Students should submit their solutions on the course blackboard site or bring printed copies to lecture. The homework contains two problems worth 20 points each. Problem 1 has two parts involving analyzing the complexity of algorithms and proving statements about logarithms and exponents. Problem 2 also has two parts, with the first requiring a proof by induction and the second containing four subproblems involving set operations, combinatorics, probability, and counting handshakes.

Uploaded by

Joseph Blanchard
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
46 views2 pages

Homework #1 Introduction To Algorithms/Algorithms 1 600.363/463 Spring 2015

This document provides instructions for Homework #1 for an algorithms course. It is due on February 3rd by 5pm and late submissions will not be accepted. Students should submit their solutions on the course blackboard site or bring printed copies to lecture. The homework contains two problems worth 20 points each. Problem 1 has two parts involving analyzing the complexity of algorithms and proving statements about logarithms and exponents. Problem 2 also has two parts, with the first requiring a proof by induction and the second containing four subproblems involving set operations, combinatorics, probability, and counting handshakes.

Uploaded by

Joseph Blanchard
Copyright
© © All Rights Reserved
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 2

Homework #1

Introduction to Algorithms/Algorithms 1
600.363/463
Spring 2015
Due on: Tuesday, February 3rd, 5pm
Late submissions: will NOT be accepted
Format: Please start each problem on a new page.
Where to submit: On blackboard, under student assessment.
Otherwise, please bring your solutions to the lecture.
January 27, 2015

Problem 1 (20 points)

1.1

(10 points)

For each statement below explain if it is true or false and prove your answer. Be as
precise as you can. The base of log is 2 unless stated otherwise.
1.

n4
log2 n

= (n2 )

2. 2n = O(3n )
3. 2n = (3n )
4. en = (2(n+3) )

5. log log n = O(log( 3 logn n ) + log(n 3))


6. Let f, g, h be positive functions. Then h(n)(f (n)+g(n)) = O(h(n)f (n)g(n))
7. Let f, g be positive functions. Then f (n) + g(n) = (max(f (n), g(n)))
 3
2
8. nn = ( en )

9. Let f and g be a positive functions. If f (n) + g(n) = (f (n)) then g(n) =


O((f (n))2 ).

1.2

(10 points)

1. Prove that

n
X
1
i=1

= O(log n).

Problem 2(20 Points)

2.1

(10 points)

Prove by induction that n! > 2n for all n >= 4.

2.2

(10 points)

1. Let A, B, C be sets. Prove that


A \ (B C) = (A \ C) (A \ B).
2. There are m books on the shelf. What is the number of different ways to
divide the books between Alice, Bob and John? What is the answer if we
request that each person gets at least k < m/3 books? (hint: you can assume
the books are identical.)
3. We have n balls. Each ball, independently and randomly, is placed into one
of n bins. What is the probability that there are no empty bins at the end of
our experiment?
4. There are n students in the class. How many different handshakes are possible?

You might also like