# | Time | Username | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
209532 | model_code | Island (NOI18_island) | C++17 | 84 ms | 2856 KiB |
This submission is migrated from previous version of oj.uz, which used different machine for grading. This submission may have different result if resubmitted.
#include <bits/stdc++.h>
using namespace std;
const int MAXN = 200004;
int N, M, cnt[MAXN], fac[MAXN];
int main() {
scanf("%d%d", &N, &M);
for (int i = 0, u, v; i < N+M-1; ++i) {
scanf("%d%d", &u, &v);
cnt[u-1]++;
cnt[v-1]++;
}
for (int i = 0; i < N+M; ++i) {
for (int k = 2; k < cnt[i]; ++k) {
printf("%d 1\n", k);
}
}
}
Compilation message (stderr)
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |