Submission #1075373

# Submission time Handle Problem Language Result Execution time Memory
1075373 2024-08-26T04:44:22 Z Cyanberry Circle selection (APIO18_circle_selection) C++14
0 / 100
177 ms 26532 KB
#include <bits/stdc++.h>
using namespace std;

int main() {
    ios::sync_with_stdio(false);
    cin.tie(0);
    unordered_map<int, int> map1, map2;
    int circles, a, b, c;
    cin>>circles;
    for (int i = 1; i <= circles; ++i) {
        cin>>a>>b>>c;
        if (map1[a] == map2[b] && map1[a] != 0) {
            cout<<map1[a]<<' ';
        } else {
            map1[a] = i;
            map2[b] = i;
            cout<<i<<' ';
        }
    }
}
# Verdict Execution time Memory Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Incorrect 0 ms 348 KB Output isn't correct
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 113 ms 14508 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 0 ms 344 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Incorrect 177 ms 26532 KB Output isn't correct
2 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Incorrect 0 ms 348 KB Output isn't correct
4 Halted 0 ms 0 KB -
# Verdict Execution time Memory Grader output
1 Correct 0 ms 344 KB Output is correct
2 Correct 0 ms 348 KB Output is correct
3 Incorrect 0 ms 348 KB Output isn't correct
4 Halted 0 ms 0 KB -