# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
29342 | 2017-07-19T03:03:22 Z | 김현수(#1165) | Party (POI11_imp) | C++14 | 1569 ms | 37296 KB |
#include<bits/stdc++.h> using namespace std; int n, m, adj[3005][3005]; bool d[3005]; int main() { scanf("%d%d",&n,&m); for(int i=1;i<=m;i++) { int A, B; scanf("%d%d",&A,&B); adj[A][B] = adj[B][A] = 1; } for(int i=1;i<=n;i++) { for(int j=i+1;j<=n;j++) { if(adj[i][j]) continue; if(!d[i] && !d[j]) d[i] = d[j] = true; } } int c = 0; for(int i=1;i<=n && c < n/3;i++) { if(!d[i]) {printf("%d ",i); c++;} } puts(""); }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 0 ms | 37296 KB | Output is correct |
2 | Correct | 0 ms | 37296 KB | Output is correct |
3 | Correct | 0 ms | 37296 KB | Output is correct |
4 | Correct | 0 ms | 37296 KB | Output is correct |
5 | Correct | 0 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 3 ms | 37296 KB | Output is correct |
2 | Correct | 39 ms | 37296 KB | Output is correct |
3 | Correct | 29 ms | 37296 KB | Output is correct |
4 | Correct | 33 ms | 37296 KB | Output is correct |
5 | Correct | 26 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 16 ms | 37296 KB | Output is correct |
2 | Correct | 133 ms | 37296 KB | Output is correct |
3 | Correct | 176 ms | 37296 KB | Output is correct |
4 | Correct | 163 ms | 37296 KB | Output is correct |
5 | Correct | 156 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 49 ms | 37296 KB | Output is correct |
2 | Correct | 353 ms | 37296 KB | Output is correct |
3 | Correct | 306 ms | 37296 KB | Output is correct |
4 | Correct | 369 ms | 37296 KB | Output is correct |
5 | Correct | 399 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 96 ms | 37296 KB | Output is correct |
2 | Correct | 489 ms | 37296 KB | Output is correct |
3 | Correct | 496 ms | 37296 KB | Output is correct |
4 | Correct | 533 ms | 37296 KB | Output is correct |
5 | Correct | 553 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 299 ms | 37296 KB | Output is correct |
2 | Correct | 626 ms | 37296 KB | Output is correct |
3 | Correct | 709 ms | 37296 KB | Output is correct |
4 | Correct | 626 ms | 37296 KB | Output is correct |
5 | Correct | 626 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 566 ms | 37296 KB | Output is correct |
2 | Correct | 883 ms | 37296 KB | Output is correct |
3 | Correct | 893 ms | 37296 KB | Output is correct |
4 | Correct | 953 ms | 37296 KB | Output is correct |
5 | Correct | 936 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 789 ms | 37296 KB | Output is correct |
2 | Correct | 1133 ms | 37296 KB | Output is correct |
3 | Correct | 1043 ms | 37296 KB | Output is correct |
4 | Correct | 1133 ms | 37296 KB | Output is correct |
5 | Correct | 1106 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1026 ms | 37296 KB | Output is correct |
2 | Correct | 1346 ms | 37296 KB | Output is correct |
3 | Correct | 1299 ms | 37296 KB | Output is correct |
4 | Correct | 1236 ms | 37296 KB | Output is correct |
5 | Correct | 1296 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1136 ms | 37296 KB | Output is correct |
2 | Correct | 1496 ms | 37296 KB | Output is correct |
3 | Correct | 1569 ms | 37296 KB | Output is correct |
4 | Correct | 1423 ms | 37296 KB | Output is correct |
5 | Correct | 1433 ms | 37296 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 1329 ms | 37296 KB | Output is correct |
2 | Correct | 1519 ms | 37296 KB | Output is correct |
3 | Correct | 1509 ms | 37296 KB | Output is correct |
4 | Correct | 1493 ms | 37296 KB | Output is correct |
5 | Correct | 1473 ms | 37296 KB | Output is correct |