I have trouble with this problem:
I thought it is the same as this problem:
http://www.spoj.pl/problems/PROFIT/
I thought it is a maximum closure problem and I solved it using network flows, but I failed on the first one. Can anyone tell me why or give me some hints?
Can you provide working link to the first problem?
UPD: The link is actually works in FF, but opera can't open it.
I think this is what you need.
I know it is a maximum closure problem actually, however, I got WA, and I want to find out why it's not correct.