Find them, Catch themTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 25758 Accepted: 7780DescriptionThe police office in Tadu City decides to say ends to the chaos, as launch actions to root up the TWO gangs in the city, Gang Dragon and
代碼留存:#include<cstdio>#include<iostream>#include<algorithm>#include<cstring>#include<vector>#include<set>#include<cmath>#include<queue>using namespace std;typedef long long LL;typedef pair<int,int>
Silver Cow PartyTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 10589 Accepted: 4690DescriptionOne cow from each of N farms (1 ≤ N ≤ 1000) conveniently numbered 1..N is going to attend the big cow party to be held at farm #X (1 ≤X ≤ N). A
WormholesTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 25394 Accepted: 9083DescriptionWhile exploring his many farms, Farmer John has discovered a number of amazing wormholes. A wormhole is very peculiar because it is a one-way path that
題目: n 架飛機,每架飛機的降落時間有兩個選擇,一個為早點降落,另一個為晚點降落;求兩架飛機降落時間差的最小值的最大值(就是怎麼安排,使得所有飛機降落的時間差的最小值盡量大)輸入:一個n,代表飛機數目;接下來n行,表示每架飛機降落的兩個時間分析:最小值盡量大,用二分尋找;對於查到一個最小值t,如果任意兩個時間差小於t,那麼這兩架飛機就不能同時降落,由此產生了條件就是時間差<t的就不能同時滿足代碼:#include <cstdio>#include
E. The Road to Berland is Paved With Good Intentionstime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputBerland has n cities, some of them are connected by bidirectional roads. For each road we know
Bound FoundTime Limit: 5000MS Memory Limit: 65536KTotal Submissions: 1338 Accepted: 443 Special JudgeDescriptionSignals of most probably extra-terrestrial origin have been received and digitalized by The Aeronautic and Space Administration (that