Problem Set 2

Practice problems relating to analysis notations.

Question 1

Suppose your friend discovers a new algorithm and in his excitement tells you that his algorithm has a lower bound of O(n2). Can you explain why your friend's statement makes no sense?

Question 2

Does O(22n) equal O(2n) ?

Question 3

Give an example of an algorithm whose best case is equal to its worst case?

Question 4

Work out the ...

Access this course and 1400+ top-rated courses and projects.