Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

(10) The greedy algorithm for the activity selection problem we discussed (Rosen

ID: 3604092 • Letter: #

Question

(10) The greedy algorithm for the activity selection problem we discussed (Rosen pp. 417-421) can be stated as "Always select the activity having the earliest finish time, discard the activities incompatible with the selection just made, and work on the resulting subproblem." Show that the following greedy strategies (that replaces the underlined part) do not always yield an optimal solution for the activity selection problem, by giving a counterexample for each. (a) Always select the activity having the least duration. (b) Always select the activity that overlaps the fewest other activities. (c) Always select the activity having the earliest start time.

Explanation / Answer

different types of planes (size) different types of gates (size, location) flight schedule randomness (weather, take off policy) service time at gate deplaning of passengers service of airplane boarding of passengers minimization of work for airline personnel minimization of airplane delay