There are N villages, which are numbered from 1 to N, and you should build some roads such that every two villages can connect to each other. We say two village A and B are connected, if and only if there is a road between A and B, or there exists a village C such that there is a road between A and C, and C and B are connected.
Sunny Cup 2003 - Preliminary Round
April 20th, 12:00 - 17:00
Problem E: QS Network
A题
题意:输入两组数,为1表示有该任务,0表示没有,现在由你定义每个任务的分数,使得最高分最小的情况下,第一个人的总分大于第二个人,如果无法满足,输出-1。