# | Submission time | Handle | Problem | Language | Result | Execution time | Memory |
---|---|---|---|---|---|---|---|
319790 | 2020-11-06T12:41:50 Z | northlake | Stations (IOI20_stations) | C++17 | 986 ms | 864 KB |
#include<stations.h> #include<bits/stdc++.h> using namespace std; vector<int> label(int n, int k, vector<int> u, vector<int> v) { vector<int> labels = {}; for (int i = 0; i < n; i++) { labels.push_back(i); } return labels; } bool is_child(int a, int b) { if (a == b) return true; if (a > b) return false; return (is_child(2*a + 1, b) || is_child(2*a + 2, b)); } int find_next_station(int s, int t, vector<int> c) { if (!is_child(s, t)) return c[0]; if (is_child(2*s + 1, t)) return (2*s + 1); if (is_child(2*s + 2, t)) return (2*s + 2); }
Compilation message
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 582 ms | 844 KB | Wrong query response. |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 492 ms | 840 KB | Output is correct |
2 | Correct | 710 ms | 756 KB | Output is correct |
3 | Correct | 905 ms | 864 KB | Output is correct |
4 | Correct | 749 ms | 736 KB | Output is correct |
5 | Correct | 769 ms | 864 KB | Output is correct |
6 | Correct | 492 ms | 756 KB | Output is correct |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 715 ms | 756 KB | Wrong query response. |
2 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Correct | 986 ms | 756 KB | Output is correct |
2 | Incorrect | 722 ms | 756 KB | Wrong query response. |
3 | Halted | 0 ms | 0 KB | - |
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
1 | Incorrect | 573 ms | 756 KB | Wrong query response. |
2 | Halted | 0 ms | 0 KB | - |