You are determined on making the most sonically pleasing playlist the world has ever heard. As a connoisseur of music, you realize that the order in which the songs are presented is just as important as the quality of the songs themselves. Your task is to compute the “best” possible order for them to appear. This shouldn't be too difficult because you are also well versed in the art of programming. For each pair of songs and you have assigned a “delight rating” , which is a positive number indicating how good sounds when played immediately after . and are generally not equal.
Given songs, you write a dynamic programming solution for just finding the maximum total delight . Which of the following is a realistic run-time of the algorithm?
Details and Assumptions
This section requires Javascript.
You are seeing this because something didn't load right. We suggest you, (a) try
refreshing the page, (b) enabling javascript if it is disabled on your browser and,
finally, (c)
loading the
non-javascript version of this page
. We're sorry about the hassle.
No explanations have been posted yet. Check back later!