Exercises 41 and 42 deal with the problem of scheduling the most talks possible given the start and end times of $n$ talks.
Find the complexity of the greedy algorithm for scheduling the most talks by adding at each step the talk with the earliest end time compatible with those already scheduled (Algorithm 7 in Section 3.1$)$ . Assume that the talks are not already sorted by earliest end time and assume that the worst-case time complexity of sorting is $O(n \log n) .$