Question: Problem 6: Create [20 points] The SXSW restival is coming up. The Cily of Austin is finalizing its plans. One problem chey noticed last year

 Problem 6: Create [20 points] The SXSW restival is coming up.

Problem 6: Create [20 points] The SXSW restival is coming up. The Cily of Austin is finalizing its plans. One problem chey noticed last year was that the plaement of trash and recycle bins along 6th street was not optimal last year. This year they want to more strategically place bins to keep trash off the street by making sure trash bins are placed along the sidewalk on each side of the street in such a way that they are within 20ft of the entrance to any establishment that serves take-away food. (a) Give an efficient greedy algorithm that finds a set of locations along one side of 6th street for placing bins that achieves the city's goal while minimizing the number of bins they have to place. State and briefly justify the runtime of your algorithm. (Hint: this is a one-dimensional problem, consider the sidewalk as a line and determine the locations along that line to place (b) Prove that the greedy choice that your algorithm makes is the optimal choice

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!