Talk:LA - Workshops

I'll give it to you straight: I have no idea how to do this problem. Neither do some of the reddest TopCoders I know. It's an NP-hard matching problem, and that's never good news when the number of objects in each set can be up to 1000.

Here's the way to think of the problem. Each workshop is a pair (p, q), where p is the number of interested participants and q is the length of time it will last. Each room is also a pair (p, q), where p is the number of people it can hold and q is the length of time it is open. We need to match as many workshops to unique rooms as possible, where pworkshop &le; proom and qworkshop &le; qroom for each matching. If more than one matching leaves the fewest number of workshops unmatched, we need to break ties based on the smallest sum of the p values for each unmatched workshop.

According to the input restrictions, 1 &le; p &le; 100 and 1 &le; q &le; 300 for both the workshops and the rooms. This means there are at most 30,000 possible points. They can't be linearly sorted, but perhaps a divide-and-conquer algorithm with memoization could be successful. --Jeff 14:13, 9 Sep 2005 (EDT)