# |
Submission time |
Handle |
Problem |
Language |
Result |
Execution time |
Memory |
619 |
2013-02-28T16:41:16 Z |
jwvg0425 |
지도 색칠하기 (GA3_map) |
C++ |
|
0 ms |
920 KB |
#include <algorithm>
int C[21][21],D[21],E[21],F[21];
int Compare(const void* a, const void* b)
{
return E[*(int*)b]-E[*(int*)a];
}
long long int NumberOfMaps(int N, int M, int* A,int* B)
{
long long int i,j,k=1;
for(i=1;i<=N;i++)F[i]=i;
for(i=0;i<M;i++)
{
C[A[i]][B[i]]=C[B[i]][A[i]]=1;
E[A[i]]++;
E[B[i]]++;
}
qsort(F+1,N,sizeof(int),Compare);
for(i=1;i<=N;i++)
{
for(j=i+1;j<=N;j++)
{
if(C[F[i]][F[j]])
{
D[F[j]]--;
}
}
}
for(i=1;i<=N;i++)
k*=D[i]+4;
return k;
}
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
920 KB |
Output is correct |
2 |
Correct |
0 ms |
920 KB |
Output is correct |
3 |
Correct |
0 ms |
920 KB |
Output is correct |
4 |
Correct |
0 ms |
920 KB |
Output is correct |
5 |
Incorrect |
0 ms |
920 KB |
Output isn't correct |
6 |
Halted |
0 ms |
0 KB |
- |
7 |
Halted |
0 ms |
0 KB |
- |
8 |
Halted |
0 ms |
0 KB |
- |
9 |
Halted |
0 ms |
0 KB |
- |
10 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
920 KB |
Output is correct |
2 |
Correct |
0 ms |
920 KB |
Output is correct |
3 |
Correct |
0 ms |
920 KB |
Output is correct |
4 |
Correct |
0 ms |
920 KB |
Output is correct |
5 |
Correct |
0 ms |
920 KB |
Output is correct |
6 |
Incorrect |
0 ms |
920 KB |
Output isn't correct |
7 |
Halted |
0 ms |
0 KB |
- |
8 |
Halted |
0 ms |
0 KB |
- |
9 |
Halted |
0 ms |
0 KB |
- |
10 |
Halted |
0 ms |
0 KB |
- |
11 |
Halted |
0 ms |
0 KB |
- |
12 |
Halted |
0 ms |
0 KB |
- |
13 |
Halted |
0 ms |
0 KB |
- |
14 |
Halted |
0 ms |
0 KB |
- |
15 |
Halted |
0 ms |
0 KB |
- |
16 |
Halted |
0 ms |
0 KB |
- |
17 |
Halted |
0 ms |
0 KB |
- |
18 |
Halted |
0 ms |
0 KB |
- |
19 |
Halted |
0 ms |
0 KB |
- |
20 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
920 KB |
Output is correct |
2 |
Correct |
0 ms |
920 KB |
Output is correct |
3 |
Correct |
0 ms |
920 KB |
Output is correct |
4 |
Correct |
0 ms |
920 KB |
Output is correct |
5 |
Correct |
0 ms |
920 KB |
Output is correct |
6 |
Incorrect |
0 ms |
920 KB |
Output isn't correct |
7 |
Halted |
0 ms |
0 KB |
- |
8 |
Halted |
0 ms |
0 KB |
- |
9 |
Halted |
0 ms |
0 KB |
- |
10 |
Halted |
0 ms |
0 KB |
- |
11 |
Halted |
0 ms |
0 KB |
- |
12 |
Halted |
0 ms |
0 KB |
- |
13 |
Halted |
0 ms |
0 KB |
- |
14 |
Halted |
0 ms |
0 KB |
- |
15 |
Halted |
0 ms |
0 KB |
- |
16 |
Halted |
0 ms |
0 KB |
- |
17 |
Halted |
0 ms |
0 KB |
- |
18 |
Halted |
0 ms |
0 KB |
- |
19 |
Halted |
0 ms |
0 KB |
- |
20 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
920 KB |
Output is correct |
2 |
Correct |
0 ms |
920 KB |
Output is correct |
3 |
Correct |
0 ms |
920 KB |
Output is correct |
4 |
Correct |
0 ms |
920 KB |
Output is correct |
5 |
Correct |
0 ms |
920 KB |
Output is correct |
6 |
Incorrect |
0 ms |
920 KB |
Output isn't correct |
7 |
Halted |
0 ms |
0 KB |
- |
8 |
Halted |
0 ms |
0 KB |
- |
9 |
Halted |
0 ms |
0 KB |
- |
10 |
Halted |
0 ms |
0 KB |
- |
11 |
Halted |
0 ms |
0 KB |
- |
12 |
Halted |
0 ms |
0 KB |
- |
13 |
Halted |
0 ms |
0 KB |
- |
14 |
Halted |
0 ms |
0 KB |
- |
15 |
Halted |
0 ms |
0 KB |
- |
16 |
Halted |
0 ms |
0 KB |
- |
17 |
Halted |
0 ms |
0 KB |
- |
18 |
Halted |
0 ms |
0 KB |
- |
19 |
Halted |
0 ms |
0 KB |
- |
20 |
Halted |
0 ms |
0 KB |
- |
# |
Verdict |
Execution time |
Memory |
Grader output |
1 |
Correct |
0 ms |
920 KB |
Output is correct |
2 |
Correct |
0 ms |
920 KB |
Output is correct |
3 |
Correct |
0 ms |
920 KB |
Output is correct |
4 |
Correct |
0 ms |
920 KB |
Output is correct |
5 |
Incorrect |
0 ms |
920 KB |
Output isn't correct |
6 |
Halted |
0 ms |
0 KB |
- |
7 |
Halted |
0 ms |
0 KB |
- |
8 |
Halted |
0 ms |
0 KB |
- |
9 |
Halted |
0 ms |
0 KB |
- |
10 |
Halted |
0 ms |
0 KB |
- |
11 |
Halted |
0 ms |
0 KB |
- |
12 |
Halted |
0 ms |
0 KB |
- |
13 |
Halted |
0 ms |
0 KB |
- |
14 |
Halted |
0 ms |
0 KB |
- |
15 |
Halted |
0 ms |
0 KB |
- |
16 |
Halted |
0 ms |
0 KB |
- |
17 |
Halted |
0 ms |
0 KB |
- |
18 |
Halted |
0 ms |
0 KB |
- |
19 |
Halted |
0 ms |
0 KB |
- |
20 |
Halted |
0 ms |
0 KB |
- |
21 |
Halted |
0 ms |
0 KB |
- |
22 |
Halted |
0 ms |
0 KB |
- |
23 |
Halted |
0 ms |
0 KB |
- |
24 |
Halted |
0 ms |
0 KB |
- |
25 |
Halted |
0 ms |
0 KB |
- |
26 |
Halted |
0 ms |
0 KB |
- |
27 |
Halted |
0 ms |
0 KB |
- |
28 |
Halted |
0 ms |
0 KB |
- |
29 |
Halted |
0 ms |
0 KB |
- |
30 |
Halted |
0 ms |
0 KB |
- |