Coming soon - Get a detailed view of why an account is flagged as spam!
view details

This post has been de-listed

It is no longer included in search results and normal feeds (front page, hot posts, subreddit posts, etc). It remains visible only via the author's post history.

2
Identifying the algorithm to use to solve a Spotify Puzzle
Post Body

I have been trying for a few weeks to read this Algorithm book by Steven Skiena to brush up on long forgotten CS concepts from college. Today I came across this Programming Puzzle on Spotify and thought I'd take a shot at identifying the algorithm that could be used to solve this problem. So I dug into the Catalog which is the second part of the book and felt like I narrowed it down to Set cover/Set packing problem. But after an hour of digging into them, I realized that neither of the algorithms fit the problem.

So I have 2 questions: 1) Am I doing it right? Is this the correct way to solve problems like these? i.e., Try and identify the underlying algorithm that would solve the problem and then use that as the starting point. Or should I just try and solve the puzzle using my logical abilities and forget about trying to apply algorithms altogether.

2) I feel like I've abstracted the problem to something that would already have a standard algorithm for:

Given a Universal Set U = {A, B, C...Z} and a bunch of subsets S1 ={A,B}, S2 ={B, C}, S3 = {A, C} ...etc. Find a subset S with the smallest number of items that would include at least one item from each of the subsets.

Ideas?

Author
Account Strength
90%
Account Age
13 years
Verified Email
Yes
Verified Flair
No
Total Karma
1,905
Link Karma
958
Comment Karma
872
Profile updated: 3 days ago
Posts updated: 7 months ago

Subreddit

Post Details

We try to extract some basic information from the post title. This is not always successful or accurate, please use your best judgement and compare these values to the post title and body for confirmation.
Posted
12 years ago