/* 先排序,然後用序號來代替 */#include<stdio.h>#include<string.h>#include<algorithm>using namespace std;struct node{ int value; int pos; }a[100];bool cmp(node a,node b){ return a.value<b.value;} int main(){ int b[100];
文章目錄 Sample inputOutput for sample input Problem B: The Largest CliqueGiven a directed graph G, consider the following transformation. First, create a new graphT(G) to have the same vertex set as G. Create a directed edge
D. Cow Programtime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputFarmer John has just given the cows a program to play with! The program contains two integer variables,x andy, and performs the
MatrixTime Limit: 6000MS Memory Limit: 65536KTotal Submissions: 4150 Accepted: 1007DescriptionGiven a N × N matrix A, whose element in the i-th row andj-th columnAij is an number that equals i2 + 100000 ×i +j2 - 100000 × j + i × j, you are to find
B. Hometasktime limit per test2 secondsmemory limit per test256 megabytesinputstandard inputoutputstandard outputFurik loves math lessons very much, so he doesn't attend them, unlike Rubik. But now Furik wants to get a good mark for math. For that
Jessica's Reading ProblemTime Limit: 1000MS Memory Limit: 65536KTotal Submissions: 5967 Accepted: 1794DescriptionJessica's a very lovely girl wooed by lots of boys. Recently she has a problem. The final exam is coming, yet she has spent little time
文章目錄 Sample InputPossible Output for Sample Input Problem E: WeddingUp to thirty couples will attend a wedding feast, at which they will be seated on either side of a long table. The bride and groom sit at one end,
Radar InstallationTime Limit: 1000MS Memory Limit: 10000KTotal Submissions: 43100 Accepted: 9543DescriptionAssume the coasting is an infinite straight line. Land is in one side of coasting, sea in the other. Each small island is a point locating in
DryingTime Limit: 2000MS Memory Limit: 65536KTotal Submissions: 7104 Accepted: 1823DescriptionIt is very hard to wash and especially to dry clothes in winter. But Jane is a very smart girl. She is not afraid of this boring process. Jane has decided